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-10 of 23 results. Next

A141018 a(n) is the largest number in the n-th row of triangle A140997.

Original entry on oeis.org

1, 1, 2, 4, 8, 15, 28, 52, 96, 177, 345, 694, 1386, 2751, 5431, 10672, 20885, 40724, 79153, 153402, 296528, 571845, 1129293, 2264749, 4527029, 9021498, 17926740, 35527082, 70230422, 138504765, 272545323, 535184340, 1048842743, 2051669285, 4006253136, 7954830148
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 11 2008

Keywords

Comments

Also the largest number of the n-th row of A140994.

Examples

			The largest number of 1 is a(0) = 1.
The largest number of 1 1 is a(1) = 1.
The largest number of 1 2 1 is a(2) = 2.
The largest number of 1 4 2 1 is a(3) = 4.
The largest number of 1 8 4 2 1 is a(4) = 8.
The largest number of 1 15 9 4 2 1 is a(5) = 15.
The largest number of 1 28 19 9 4 2 1 is a(6) = 28.
The largest number of 1 52 40 19 9 4 2 1 is a(7) = 52.
		

Crossrefs

Programs

  • Maple
    A140997 := proc(n,k) option remember ; if k<0 or k>n then 0 ; elif k=0 or k=n then 1 ; elif k=n-1 then 2 ; elif k=n-2 then 4 ; else procname(n-1,k)+procname(n-2,k)+procname(n-3,k)+procname(n-3,k-1) ; fi; end:
    A141018 := proc(n) max(seq(A140997(n,k),k=0..n)) ; end: for n from 0 to 60 do printf("%d,",A141018(n)) ; od: # R. J. Mathar, Sep 19 2008
  • Mathematica
    T[n_, k_] := T[n, k] = Which[k < 0 || k > n, 0, k == 0 || k == n, 1, k == n-1, 2, k == n-2, 4, True, T[n-1, k]+T[n-2, k]+T[n-3, k]+T[n-3, k-1]];
    a[n_] := Max[Table[T[n, k], {k, 0, n}]];
    Table[a[n], {n, 0, 60}] (* Jean-François Alcover, Oct 18 2023, after R. J. Mathar *)

Extensions

Partially edited by N. J. A. Sloane, Jul 18 2008
Simplified definition, corrected from a(12) on and extended by R. J. Mathar, Sep 19 2008

A008937 a(n) = Sum_{k=0..n} T(k) where T(n) are the tribonacci numbers A000073.

Original entry on oeis.org

0, 1, 2, 4, 8, 15, 28, 52, 96, 177, 326, 600, 1104, 2031, 3736, 6872, 12640, 23249, 42762, 78652, 144664, 266079, 489396, 900140, 1655616, 3045153, 5600910, 10301680, 18947744, 34850335, 64099760, 117897840, 216847936, 398845537, 733591314, 1349284788
Offset: 0

Views

Author

N. J. A. Sloane, Alejandro Teruel (teruel(AT)usb.ve)

Keywords

Comments

a(n+1) is the number of n-bit sequences that avoid 1100. - David Callan, Jul 19 2004 [corrected by Kent E. Morrison, Jan 08 2019]. Also the number of n-bit sequences avoiding one of the patterns 1000, 0011, 1110, ... or any binary string of length 4 without overlap at beginning and end. Strings where it is not true are: 1111, 1010, 1001, ... and their bitwise complements. - Alois P. Heinz, Jan 09 2019
Row sums of Riordan array (1/(1-x), x(1+x+x^2)). - Paul Barry, Feb 16 2005
Diagonal sums of Riordan array (1/(1-x)^2, x(1+x)/(1-x)), A104698.
A shifted version of this sequence can be found in Eqs. (4) and (3) on p. 356 of Dunkel (1925) with r = 3. (Equation (3) follows equation (4) in the paper!) The whole paper is a study of the properties of this and other similar sequences indexed by the parameter r. For r = 2, we get a shifted version of A000071. For r = 4, we get a shifted version of A107066. For r = 5, we get a shifted version of A001949. For r = 6, we get a shifted version of A172316. See also the table in A172119. - Petros Hadjicostas, Jun 14 2019
Officially, to match A000073, this should start with a(0)=a(1)=0, a(2)=1. - N. J. A. Sloane, Sep 12 2020
Numbers with tribonacci representation that is a prefix of 100100100100... . - Jeffrey Shallit, Jul 10 2024

Examples

			G.f. = x + 2*x^2 + 4*x^3 + 8*x^4 + 15*x^5 + 28*x^6 + 52*x^7 + 96*x^8 + 177*x^9 + ... [edited by _Petros Hadjicostas_, Jun 12 2019]
		

References

  • A. T. Benjamin and J. J. Quinn, Proofs that really count: the art of combinatorial proof, M.A.A. 2003, p. 41.

Crossrefs

Partial sums of A000073. Cf. A000213, A018921, A027084, A077908, A209972.
Row sums of A055216.
Column k = 1 of A140997 and second main diagonal of A140994.

Programs

  • GAP
    a:=[0,1,1];; for n in [4..40] do a[n]:=a[n-1]+a[n-2]+a[n-3]; od; a; # G. C. Greubel, Sep 13 2019
  • Haskell
    a008937 n = a008937_list !! n
    a008937_list = tail $ scanl1 (+) a000073_list
    -- Reinhard Zumkeller, Apr 07 2012
    
  • Magma
    [ n eq 1 select 0 else n eq 2 select 1 else n eq 3 select 2 else n eq 4 select 4 else 2*Self(n-1)-Self(n-4): n in [1..40] ]; // Vincenzo Librandi, Aug 21 2011
    
  • Maple
    A008937 := proc(n) option remember; if n <= 3 then 2^n else 2*procname(n-1)-procname(n-4) fi; end;
    a:= n-> (Matrix([[1,1,0,0], [1,0,1,0], [1,0,0,0], [1,0,0,1]])^n)[4,1]: seq(a(n), n=0..50); # Alois P. Heinz, Jul 24 2008
  • Mathematica
    CoefficientList[Series[x/(1-2x+x^4), {x, 0, 40}], x]
    Accumulate[LinearRecurrence[{1,1,1},{0,1,1},40]] (* Harvey P. Dale, Dec 04 2017 *)
    LinearRecurrence[{2, 0, 0, -1},{0, 1, 2, 4},40] (* Ray Chandler, Mar 01 2024 *)
  • PARI
    {a(n) = if( n<0, polcoeff( - x^3 / (1 - 2*x^3 + x^4) + x * O(x^-n), -n), polcoeff( x / (1 - 2*x + x^4) + x * O(x^n), n))}; /* Michael Somos, Aug 23 2014 */
    
  • PARI
    a(n) = sum(j=0, n\2, sum(k=0, j, binomial(n-2*j,k+1)*binomial(j,k)*2^k)); \\ Michel Marcus, Sep 08 2017
    
  • SageMath
    def A008937_list(prec):
        P = PowerSeriesRing(ZZ, 'x', prec)
        x = P.gen().O(prec)
        return (x/(1-2*x+x^4)).list()
    A008937_list(40) # G. C. Greubel, Sep 13 2019
    

Formula

a(n) = A018921(n-2) = A027084(n+1) + 1.
a(n) = (A000073(n+2) + A000073(n+4) - 1)/2.
From Mario Catalani (mario.catalani(AT)unito.it), Aug 09 2002: (Start)
G.f.: x/((1-x)*(1-x-x^2-x^3)).
a(n) = 2*a(n-1) - a(n-4), a(0) = 0, a(1) = 1, a(2) = 2, a(3) = 4. (End)
a(n) = 1 + a(n-1) + a(n-2) + a(n-3). E.g., a(11) = 1 + 600 + 326 + 177 = 1104. - Philippe LALLOUET (philip.lallouet(AT)orange.fr), Oct 29 2007
a(n) = term (4,1) in the 4 X 4 matrix [1,1,0,0; 1,0,1,0; 1,0,0,0; 1,0,0,1]^n. - Alois P. Heinz, Jul 24 2008
a(n) = -A077908(-n-3). - Alois P. Heinz, Jul 24 2008
a(n) = (A000213(n+2) - 1) / 2. - Reinhard Zumkeller, Apr 07 2012
a(n) = Sum_{j=0..floor(n/2)} Sum_{k=0..j} binomial(n-2j,k+1) *binomial(j,k)*2^k. - Tony Foster III, Sep 08 2017
a(n) = Sum_{k=0..floor(n/2)} (n-2*k)*hypergeom([-k,-n+2*k+1], [2], 2). - Peter Luschny, Nov 09 2017
a(n) = 2^(n-1)*hypergeom([1-n/4, 1/4-n/4, 3/4-n/4, 1/2-n/4], [1-n/3, 1/3-n/3, 2/3-n/3], 16/27) for n > 0. - Peter Luschny, Aug 20 2020
a(n-1) = T(n) + T(n-3) + T(n-6) + ... + T(2+((n-2) mod 3)), for n >= 4, where T is A000073(n+1). - Jeffrey Shallit, Dec 24 2020

A140993 Triangle G(n, k) read by rows, for 1 <= k <= n, where G(n, n) = G(n+1, 1) = 1, G(n+2, 2) = 2, G(n+3, m) = G(n+1, m-1) + G(n+1, m-2) + G(n+2, m-1) for n >= 1 and m = 3..(n+2).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 2, 4, 1, 1, 2, 5, 7, 1, 1, 2, 5, 11, 12, 1, 1, 2, 5, 12, 23, 20, 1, 1, 2, 5, 12, 28, 46, 33, 1, 1, 2, 5, 12, 29, 63, 89, 54, 1, 1, 2, 5, 12, 29, 69, 137, 168, 88, 1, 1, 2, 5, 12, 29, 70, 161, 289, 311, 143, 1, 1, 2, 5, 12, 29, 70, 168, 367, 594, 567, 232, 1, 1, 2, 5, 12, 29, 70, 169, 399, 817, 1194, 1021, 376, 1
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jul 08 2008

Keywords

Comments

From Petros Hadjicostas, Jun 10 2019: (Start)
Let b(m) = lim_{n -> infinity} G(n, m) for each m >= 1. Then b(1) = 1, b(2) = 2, and b(m) = 2*b(m-1) + b(m-2) for m >= 3. (The existence of the limit can be proved by induction on m.) This means b(m) = A000129(m) for m >= 1 (known as the Pell numbers).
If we want to get the second main diagonal, we let c(n) = G(n+1, n) for n >= 1. Then c(n+2) = G(n+3, n+2) = G(n+1, n+1) + G(n+1, n) + G(n+2, n+1) = 1 + c(n) + c(n+1) with c(1) = G(2, 1) = 1 and c(2) = G(3, 2) = 2, which implies that c(n) = A000071(n+2) = Fibonacci(n+2) - 1 for n >= 1.
This array is the mirror image of A140998 (except for a shifting of the indices by 1). Thus, G(n, k) = A140998(n - 1, n - k) for 1 <= k <= n. This array has index of obliqueness e = 1, while array A140998 has index of obliqueness e = 0. Both arrays have the same index of asymmetry (s = 1). (End)
From Petros Hadjicostas, Feb 09 2021: (Start)
One of the two rectangular versions, say (RA(n,k): n,k >= 0), of this triangular array (G(n,k): 1 <= k <= n) is given by RA(n,k) = G(n+k-1,k) for n,k >= 1. Conversely, G(n,k) = RA(n-k+1, k) for 1 <= k <= n. (This assumes that the triangle G(n,k) is read from the array RA(n,k) by ascending antidiagonals.)
Note that [o.g.f of RA](x,y) = x*[o.g.f. of G](x, y/x) and [o.g.f of G](x,y) = x^(-1)*[o.g.f of RA](x,x*y).
The other rectangular version, say (RD(n,k): n,k >= 0), of this triangular array (G(n,k): 1 <= k <= n) is given by RD(n,k) = RA(k,n) = G(n+k-1,n) for n,k >= 1. Conversely, G(n,k) = RD(k,n-k+1) for 1 <= k <= n. (This assumes that the triangle G(n,k) is read from the array RD(n,k) by descending antidiagonals.)
Note that [o.g.f of RD](x,y) = y*[o.g.f. of G](y,x/y) and [o.g.f of G](x,y) = x^(-1)*[o.g.f of RD](x*y, x). (End)

Examples

			Triangle G(n,k) (with rows for n >= 1 and columns for 1 <= k <= n) begins:
  1
  1 1
  1 2 1
  1 2 4  1
  1 2 5  7  1
  1 2 5 11 12  1
  1 2 5 12 23 20   1
  1 2 5 12 28 46  33   1
  1 2 5 12 29 63  89  54   1
  1 2 5 12 29 69 137 168  88    1
  1 2 5 12 29 70 161 289 311  143    1
  1 2 5 12 29 70 168 367 594  567  232    1
  1 2 5 12 29 70 169 399 817 1194 1021  376   1
  1 2 5 12 29 70 169 407 934 1778 2355 1820 609 1
  ...
From _Petros Hadjicostas_, Feb 09 2021: (Start)
Rectangular array RA(n,k) (with rows for n >= 1 and columns for k >= 1) begins:
  1, 1, 1,  1,  1,  1,   1,   1,   1,    1, ...
  1, 2, 4,  7, 12, 20,  33,  54,  88,  143, ...
  1, 2, 5, 11, 23, 46,  89, 168, 311,  567, ...
  1, 2, 5, 12, 28, 63, 137, 289, 594, 1194, ...
  1, 2, 5, 12, 29, 69, 161, 367, 817, 1778, ...
  1, 2, 5, 12, 29, 70, 168, 399, 934, 2150, ...
  1, 2, 5, 12, 29, 70, 169, 407, 975, 2316, ...
  1, 2, 5, 12, 29, 70, 169, 408, 984, 2367, ...
  1, 2, 5, 12, 29, 70, 169, 408, 985, 2377, ...
  1, 2, 5, 12, 29, 70, 169, 408, 985, 2378, ...
  ...
Reading the array RA(n,k) by ascending antidiagonals, we get triangle G(n,k) above. (End)
		

Crossrefs

Programs

  • Maple
    A140993 := proc(n,k) if k = n then 1; elif k = 1 then 1; elif k = 2 then 2; else procname(n-2,k-1)+procname(n-2,k-2)+procname(n-1,k-1) ; end if; end proc: seq(seq(A140993(n,k),k=1..n),n=1..15) ; # R. J. Mathar, Apr 28 2010
  • Mathematica
    t[n_, k_] := If[k == n, 1, If[k == 1, 1, If[k == 2, 2, t[n - 2, k - 1] + t[n - 2, k - 2] + t[n - 1, k - 1]]]]; Flatten[Table[ t[n, k], {n, 13}, {k, n}]] (* Robert G. Wilson v, Dec 22 2011 *)

Formula

From Petros Hadjicostas, Jun 10 2019: (Start)
G(n, k) = A140998(n - 1, n - k) for 1 <= k <= n.
Bivariate o.g.f.: Sum_{n >= 1, k >= 1} G(n, k)*x^n*y^k = x*y*(1 - x*y -x^2*y^2 + x^3*y^2)/((1 - x) * (1 - x*y) * (1 - x*y - x^2*y - x^2*y^2)). (Here, we let G(n, k) = 0 when 1 <= n < k.)
To get the row sums, we let y = 1 in the above bivariate g.f. and simplify. We get x/(1 - 2*x), which is the g.f. of sequence (A000079(n-1): n >= 1) = (2^(n-1): n >= 1). (End)
From Petros Hadjicostas, Feb 10 2021: (Start)
We give formulas about the rectangular array RA(n,k).
Initial conditions: RA(1,n) = RA(n+1,1) = 1 and RA(n+1,2) = 2 for n >= 1.
Recurrence: RA(n,k) = RA(n-1,k-1) + RA(n,k-2) + RA(n,k-1) for n >= 2 and k >= 3.
The main diagonal of the array is RA(n,n) = A000129(n) (Pell numbers).
Bivariate o.g.f: Sum_{n,k >= 1} RA(n,m)*x^n*y^k = x*y*(x*y^2 - y^2 - y + 1)/((1 - x)*(1 - y)*(-x*y - y^2 - y + 1)).
To obtain formulas about the other rectangular array, RD(n,k), we use the equations RD(n,k) = RA(k,n) for n,k >= 1 and [o.g.f. of RD](x,y) = [o.g.f. of RA](y,x). (End)

Extensions

Entries checked by R. J. Mathar, Apr 28 2010
Name and offset edited by Petros Hadjicostas, Jun 10 2019

A140994 Triangle G(n, k), for 0 <= k <= n, read by rows, where G(n, n) = G(n+1, 0) = 1, G(n+2, 1) = 2, G(n+3, 2) = 4, G(n+4, m) = G(n+1, m-2) + G(n+1, m-3) + G(n+2, m-2) + G(n+3, m-1) for n >= 0 and m = 3..(n+3).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 2, 4, 1, 1, 2, 4, 8, 1, 1, 2, 4, 9, 15, 1, 1, 2, 4, 9, 19, 28, 1, 1, 2, 4, 9, 19, 40, 52, 1, 1, 2, 4, 9, 19, 41, 83, 96, 1, 1, 2, 4, 9, 19, 41, 88, 170, 177, 1, 1, 2, 4, 9, 19, 41, 88, 188, 345, 326, 1, 1, 2, 4, 9, 19, 41, 88, 189, 400, 694, 600, 1, 1, 2, 4, 9, 19, 41, 88, 189, 406, 846, 1386, 1104, 1
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 08 2008

Keywords

Comments

From Petros Hadjicostas, Jun 12 2019: (Start)
This is a mirror image of the triangular array A140997. The current array has index of asymmetry s = 2 and index of obliqueness (obliquity) e = 1. Array A140997 has the same index of asymmetry, but has index of obliqueness e = 0. (In other related sequences, the author uses the letter y for the index of asymmetry and the letter z for the index of obliqueness, but on the stone slab that appears over a tomb in a picture that he posted in those sequences, the letters s and e are used instead. See, for example, the documentation for sequences A140998, A141065, A141066, and A141067.)
In general, if the index of asymmetry (from the Pascal triangle A007318) is s, then the order of the recurrence is s + 2 (because the recurrence of the Pascal triangle has order 2). There are also s + 2 infinite sets of initial conditions (as opposed to the Pascal triangle, which has only 2 infinite sets of initial conditions, namely, G(n, 0) = G(n+1, n+1) = 1 for n >= 0).
Pascal's triangle A007318 has s = 0 and is symmetric, arrays A140998 and A140993 have s = 1 (with e = 0 and e = 1, respectively), and arrays A140996 and A140995 have s = 3 (with e = 0 and e = 1, respectively).
If A(x,y) = Sum_{n,k >= 0} G(n, k)*x^n*y^k is the bivariate g.f. for this array (with G(n, k) = 0 for 0 <= n < k) and B(x, y) = Sum_{n, k} A140997(n, k)*x^n*y^k, then A(x, y) = B(x*y, y^(-1)). This can be proved using formal manipulation of double series expansions and the fact G(n, k) = A140997(n, n-k) for 0 <= k <= n.
If we let b(k) = lim_{n -> infinity} G(n, k) for k >= 0, then b(0) = 1, b(1) = 2, b(2) = 4, and b(k) = b(k-1) + 2*b(k-2) + b(k-3) for k >= 3. (The existence of the limit can be proved by induction on k.) It follows that b(k) = A141015(k) for k >= 0.
(End)

Examples

			Triangle begins:
  1
  1 1
  1 2 1
  1 2 4 1
  1 2 4 8 1
  1 2 4 9 15  1
  1 2 4 9 19 28  1
  1 2 4 9 19 40 52   1
  1 2 4 9 19 41 83  96   1
  1 2 4 9 19 41 88 170 177    1
  1 2 4 9 19 41 88 188 345  326    1
  1 2 4 9 19 41 88 189 400  694  600    1
  1 2 4 9 19 41 88 189 406  846 1386 1104 1
... [corrected by _Petros Hadjicostas_, Jun 12 2019]
E.g., G(12, 9) = G(9, 7) + G(9, 6) + G(10, 7) + G(11, 8) = 170 + 88 + 188 + 400 = 846.
		

Crossrefs

Programs

  • Maple
    G := proc(n,k) if k=0 or n =k then 1; elif k= 1 then 2 ; elif k =2 then 4; elif k > n or k < 0 then 0 ; else procname(n-3,k-2)+procname(n-3,k-3)+procname(n-2,k-2)+procname(n-1,k-1) ; end if; end proc: seq(seq(G(n,k),k=0..n),n=0..15) ; # R. J. Mathar, Apr 14 2010
  • Mathematica
    nlim = 50;
    Do[G[n, 0] = 1, {n, 0, nlim}];
    Do[G[n, n] = 1, {n, 1, nlim}];
    Do[G[n + 2, 1] = 2, {n, 0, nlim}];
    Do[G[n + 3, 2] = 4, {n, 0, nlim}];
    Do[G[n + 4, m] =
       G[n + 1, m - 2] + G[n + 1, m - 3] + G[n + 2, m - 2] +
        G[n + 3, m - 1], {n, 0, nlim}, {m, 3, n + 3}];
    A140994 = {}; For[n = 0, n <= nlim, n++,
     For[k = 0, k <= n, k++, AppendTo[A140994, G[n, k]]]];
    A140994 (* Robert Price, Aug 19 2019 *)

Formula

From Petros Hadjicostas, Jun 12 2019: (Start)
G(n, k) = A140997(n, n-k) for 0 <= k <= n.
Bivariate g.f.: Sum_{n,k >= 0} G(n, k)*x^n*y^k = (x^4*y^3 - x^3*y^3 - x^2*y^2 + x^2*y - x*y + 1)/((1- x*y)*(1 - x)*(1- x*y - x^2*y^2 - x^3*y^3 - x^3*y^2)).
(End)

Extensions

Entries checked by R. J. Mathar, Apr 14 2010

A140998 Triangle G(n, k), read by rows, for 0 <= k <= n, where G(n, 0) = G(n+1, n+1) = 1, G(n+2, n+1) = 2, and G(n+3, m) = G(n+1, m-1) + G(n+1, m) + G(n+2, m) for n >= 0 and m = 1..n+1.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 2, 1, 1, 7, 5, 2, 1, 1, 12, 11, 5, 2, 1, 1, 20, 23, 12, 5, 2, 1, 1, 33, 46, 28, 12, 5, 2, 1, 1, 54, 89, 63, 29, 12, 5, 2, 1, 1, 88, 168, 137, 69, 29, 12, 5, 2, 1, 1, 143, 311, 289, 161, 70, 29, 12, 5, 2, 1, 1, 232, 567, 594, 367, 168, 70, 29, 12, 5, 2, 1
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 08 2008

Keywords

Comments

From Petros Hadjicostas, Jun 10 2019: (Start)
According to the attached picture, the index of asymmetry here is s = 1 and the index of obliqueness (or obliquity) is e = 0.
In the picture, the equation G(n, e*n) = 1 becomes G(n, 0) = 1, while the equations G(n+x+1, n-e*n+e*x-e+1) = 2^x for 0 <= x < s = 1 become G(n+1, n+1) = 1 and G(n+2, n+1) = 2.
Also, in the picture, the recurrence G(n+s+2, k) = G(n+1, k-e*s+e-1) + Sum_{m=1..s+1} G(n+m, k-e*s+m*e-2*e) for k = 1..n+1 becomes G(n+3, k) = G(n+1, k-1) + G(n+1, k) + G(n+2, k) for k = 1..n+1.
Except for a shifting of the indices by 1, this array is a mirror image of array A140993. We have G(n, k) = A140993(n+1, n-k+1) for 0 <= k <= n. Triangular array A140993 has the same index of asymmetry (i.e., s = 1) but index of obliqueness e = 1.
(End)

Examples

			Triangle begins (with rows for n >= 0 and columns for k >= 0):
  1;
  1,   1;
  1,   2,   1;
  1,   4,   2,   1;
  1,   7,   5,   2,   1;
  1,  12,  11,   5,   2,   1;
  1,  20,  23,  12,   5,   2,   1;
  1,  33,  46,  28,  12,   5,   2,   1;
  1,  54,  89,  63,  29,  12,   5,   2,   1;
  1,  88, 168, 137,  69,  29,  12,   5,   2,   1;
  1, 143, 311, 289, 161,  70,  29,  12,   5,   2,   1;
		

Crossrefs

Programs

  • Mathematica
    G[n_,k_] := G[n,k] = Which[k==0 || k==n, 1, k==n-1, 2, True, G[n-2,k-1] + G[n-2,k] + G[n-1,k]]; Table[G[n,k], {n,0,12}, {k,0,n}] (* Jean-François Alcover, Jun 09 2019 *)
  • PARI
    G(n,k) = if(k==0 || k==n, 1, if(k==n-1, 2, G(n-1, k) + G(n-2, k) + G(n-2, k-1)));
    for(n=0,12, for(k=0,n, print1(G(n,k), ", "))) \\ G. C. Greubel, Jun 09 2019
    
  • Sage
    def G(n,k):
        if (k==0 or k==n): return 1
        elif (k==n-1): return 2
        else: return G(n-1, k) + G(n-2, k) + G(n-2, k-1)
    [[G(n,k) for k in (0..n)] for n in (0..12)] # G. C. Greubel, Jun 09 2019

Formula

From Petros Hadjicostas, Jun 10 2019: (Start)
G(n, k) = A140993(n+1, n-k+1) for 0 <= k <= n.
Let A(x,y) = Sum_{n,k >= 0} G(n, k)*x^n*y^k and B(x,y) = Sum_{n,k >= 1} A140993(n, k). Then A(x, y) = x^(-1) * B(x*y, y^(-1)). Thus, the g.f. of the current array is A(x, y) = (1 - x - x^2 + x^3*y)/((1 - x) * (1 - x*y) * (1 - x - x^2 - x^2*y)).
To find the g.f. of the k-th column (where k >= 0), we differentiate A(x, y) k times with respect to y, divide by k!, and substitute y = 0. For example, differentiating A(x, y) once w.r.t. y and setting y = 0, we get the g.f. of the k = 1 column: x/((1 - x)*(1 - x - x^2)). This is the g.f. of sequence (A000071(n+2): n >= 0) = (Fibonacci(n+2) - 1: n >= 0).
G.f. of column k = 2 is x^2*(1 - x + x^3)/((1 - x)*(1 - x - x^2)^2). Thus, column k = 2 is a shifted version of (A140992(n): n >= 0).
(End)

Extensions

Indices in the definition corrected by R. J. Mathar, Aug 02 2009
Name edited by Petros Hadjicostas, Jun 10 2019

A140996 Triangle G(n, k) read by rows for 0 <= k <= n, where G(n, 0) = G(n+1, n+1) = 1, G(n+2, n+1) = 2, G(n+3, n+1) = 4, G(n+4, n+1) = 8, and G(n+5, m) = G(n+1, m-1) + G(n+1, m) + G(n+2, m) + G(n+3, m) + G(n+4, m) for n >= 0 for m = 1..(n+1).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 2, 1, 1, 8, 4, 2, 1, 1, 16, 8, 4, 2, 1, 1, 31, 17, 8, 4, 2, 1, 1, 60, 35, 17, 8, 4, 2, 1, 1, 116, 72, 35, 17, 8, 4, 2, 1, 1, 224, 148, 72, 35, 17, 8, 4, 2, 1, 1, 432, 303, 149, 72, 35, 17, 8, 4, 2, 1, 1, 833, 618, 308, 149, 72, 35, 17, 8, 4, 2, 1, 1, 1606, 1257, 636, 308, 149, 72, 35, 17, 8, 4, 2, 1
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 08 2008

Keywords

Comments

From Petros Hadjicostas, Jun 12 2019: (Start)
This is a mirror image of the triangular array A140995. The current array has index of asymmetry s = 3 and index of obliqueness (obliquity) e = 0. Array A140995 has the same index of asymmetry, but has index of obliqueness e = 1. (In other related sequences, the author uses the letter y for the index of asymmetry and the letter z for the index of obliqueness, but on the stone slab that appears over a tomb in a picture that he posted in those sequences, the letters s and e are used instead. See, for example, the documentation for sequences A140998, A141065, A141066, and A141067.)
In general, if the index of asymmetry (from the Pascal triangle A007318) is s, then the order of the recurrence is s + 2 (because the recurrence of the Pascal triangle has order 2). There are also s + 2 infinite sets of initial conditions (as opposed to the Pascal triangle, which has only 2 infinite sets of initial conditions, namely, G(n, 0) = G(n+1, n+1) = 1 for n >= 0).
Pascal's triangle A007318 has s = 0 and is symmetric, arrays A140998 and A140993 have s = 1 (with e = 0 and e = 1, respectively), arrays A140997 and A140994 have s = 2 (with e = 0 and e = 1, respectively), and arrays A141020 and A141021 have s = 4 (with e = 0 and e = 1, respectively).
(End)

Examples

			Triangle (with rows n >= 0 and columns k >= 0) begins as follows:
  1
  1   1
  1   2   1
  1   4   2   1
  1   8   4   2   1
  1  16   8   4   2  1
  1  31  17   8   4  2  1
  1  60  35  17   8  4  2  1
  1 116  72  35  17  8  4  2 1
  1 224 148  72  35 17  8  4 2 1
  1 432 303 149  72 35 17  8 4 2 1
  1 833 618 308 149 72 35 17 8 4 2 1
  ...
		

Crossrefs

Programs

  • Mathematica
    nlim = 100;
    For[n = 0, n <= nlim, n++, G[n, 0] = 1];
    For[n = 1, n <= nlim, n++, G[n, n] = 1];
    For[n = 2, n <= nlim, n++, G[n, n-1] = 2];
    For[n = 3, n <= nlim, n++, G[n, n-2] = 4];
    For[n = 4, n <= nlim, n++, G[n, n-3] = 8];
    For[n = 5, n <= nlim, n++, For[k = 1, k < n - 3, k++,
       G[n, k] = G[n-4, k-1] + G[n-4, k] + G[n-3, k] + G[n-2, k] + G[n-1, k]]];
    A140996 = {}; For[n = 0, n <= nlim, n++,
    For[k = 0, k <= n, k++, AppendTo[A140996, G[n, k]]]];
    A140996 (* Robert Price, Jul 03 2019 *)
    G[n_, k_] := G[n, k] = Which[k < 0 || k > n, 0, k == 0 || k == n, 1, k == n - 1, 2, k == n - 2, 4, k == n - 3, 8, True, G[n - 1, k] + G[n - 2, k] + G[n - 3, k] + G[n - 4, k] + G[n - 4, k - 1]];
    Table[G[n, k], {n, 0, 12}, {k, 0, n}] // Flatten (* Jean-François Alcover, Jan 28 2024 *)

Formula

From Petros Hadjicostas, Jun 12 2019: (Start)
G(n, k) = A140995(n, n - k) for 0 <= k <= n.
Bivariate g.f.: Sum_{n,k >= 0} G(n, k)*x^n*y^k = (1 - x - x^2 - x^3 - x^4 + x^2*y + x^3*y + x^5*y)/((1 - x) * (1 - x*y) * (1 - x - x^2 - x^3 - x^4 - x^4*y)).
If we take the first derivative of the bivariate g.f. w.r.t. y and set y = 0, we get the g.f. of column k = 1: x/((1 - x) * (1 - x - x^2 - x^3 - x^4)). This is the g.f. of a shifted version of sequence A107066.
Substituting y = 1 in the above bivariate function and simplifying, we get the g.f. of row sums: 1/(1 - 2*x). Hence, the row sums are powers of 2; i.e., A000079.
(End)

Extensions

Name edited by Petros Hadjicostas, Jun 12 2019

A140995 Triangle G(n, k) read by rows, for 0 <= k <= n, where G(n, n) = G(n+1, 0) = 1, G(n+2, 1) = 2, G(n+3, 2) = 4, G(n+4, 3) = 8, and G(n+5, m) = G(n+1, m-3) + G(n+1, m-4) + G(n+2, m-3) + G(n+3, m-2) + G(n+4, m-1) for n >= 0 and m = 4..(n+4).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 2, 4, 1, 1, 2, 4, 8, 1, 1, 2, 4, 8, 16, 1, 1, 2, 4, 8, 17, 31, 1, 1, 2, 4, 8, 17, 35, 60, 1, 1, 2, 4, 8, 17, 35, 72, 116, 1, 1, 2, 4, 8, 17, 35, 72, 148, 224, 1, 1, 2, 4, 8, 17, 35, 72, 149, 303, 432, 1, 1, 2, 4, 8, 17, 35, 72, 149, 308, 618, 833, 1, 1, 2, 4, 8, 17, 35, 72, 149, 308, 636, 1257, 1606, 1
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 08 2008

Keywords

Comments

From Petros Hadjicostas, Jun 13 2019: (Start)
This is a mirror image of the triangular array A140996. The current array has index of asymmetry s = 3 and index of obliqueness (obliquity) e = 1. Array A140996 has the same index of asymmetry, but has index of obliqueness e = 0. (In other related sequences, the author uses the letter y for the index of asymmetry and the letter z for the index of obliqueness, but in a picture that he posted in those sequences, the letters s and e are used instead. See, for example, the documentation for sequences A140998, A141065, A141066, and A141067.)
Pascal's triangle A007318 has s = 0 and is symmetric, arrays A140998 and A140993 have s = 1 (with e = 0 and e = 1, respectively), and arrays A140997 and A140994 have s = 2 (with e = 0 and e = 1, respectively).
If A(x,y) = Sum_{n,k >= 0} G(n, k)*x^n*y^k is the bivariate g.f. for this array (with G(n, k) = 0 for 0 <= n < k) and B(x, y) = Sum_{n, k} A140996(n, k)*x^n*y^k, then A(x, y) = B(x*y, y^(-1)). This can be proved using formal manipulation of double series expansions and the fact G(n, k) = A140996(n, n-k) for 0 <= k <= n.
If we let b(k) = lim_{n -> infinity} G(n, k) for k >= 0, then b(0) = 1, b(1) = 2, b(2) = 4, b(3) = 8, and b(k) = b(k-1) + b(k-2) + 2*b(k-3) + b(k-4) for k >= 4. (The existence of the limit can be proved by induction on k.) Thus, the limiting sequence is 1, 2, 4, 8, 17, 35, 72, 149, 308, 636, 1314, 2715, 5609, 11588, 23941, 49462, 102188, 211120, 436173, ... (sequence A309462). (End)

Examples

			Triangle begins:
  1
  1 1
  1 2 1
  1 2 4 1
  1 2 4 8  1
  1 2 4 8 16  1
  1 2 4 8 17 31  1
  1 2 4 8 17 35 60   1
  1 2 4 8 17 35 72 116   1
  1 2 4 8 17 35 72 148 224   1
  1 2 4 8 17 35 72 149 303 432   1
  1 2 4 8 17 35 72 149 308 618 833 1
  ...
		

Crossrefs

Formula

From Petros Hadjicostas, Jun 13 2019: (Start)
G(n, k) = A140996(n, n-k) for 0 <= k <= n.
Bivariate g.f.: Sum_{n,k >= 0} G(n, k)*x^n*y^k = (x^5*y^4 - x^4*y^4 - x^3*y^3 + x^3*y^2 - x^2*y^2 + x^2*y - x*y + 1)/((1- x*y) * (1- x) * (1 - x*y - x^2*y^2 -x^3*y^3 - x^4*y^4 - x^4*y^3)).
Substituting y = 1 in the above bivariate function and simplifying, we get the g.f. of row sums: 1/(1 - 2*x). Hence, the row sums are powers of 2; i.e., A000079.
(End)

Extensions

Entries checked by R. J. Mathar, Apr 14 2010
Name edited by and more terms from Petros Hadjicostas, Jun 13 2019

A141021 Pascal-like triangle with index of asymmetry y = 4 and index of obliqueness z = 1.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 2, 4, 1, 1, 2, 4, 8, 1, 1, 2, 4, 8, 16, 1, 1, 2, 4, 8, 16, 32, 1, 1, 2, 4, 8, 16, 33, 63, 1, 1, 2, 4, 8, 16, 33, 67, 124, 1, 1, 2, 4, 8, 16, 33, 67, 136, 244, 1, 1, 2, 4, 8, 16, 33, 67, 136, 276, 480, 1
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 11 2008

Keywords

Comments

The triangle here is A141020 with each row reversed.
From Petros Hadjicostas, Jun 16 2019: (Start)
In the attached photograph, we see that the index of asymmetry is denoted by s (rather than y) and the index of obliqueness by e (rather than z).
The general recurrence is G(n+s+2, k) = G(n+1, k-e*s+e-1) + Sum_{1 <= m <= s+1} G(n+m, k-e*s+m*e-2*e) for n >= 0 with k = 1..(n+1) when e = 0 and k = (s+1)..(n+s+1) when e = 1. The initial conditions are G(n+x+1, n-e*n+e*x-e+1) = 2^x for x=0..s and n >= 0. There is one more initial condition, namely, G(n, e*n) = 1 for n >= 0.
For s = 0, we get Pascal's triangle A007318. For s = 1, we get A140998 (e = 0) and A140993 (e = 1). For s = 2, we get A140997 (e = 0) and A140994 (e = 1). For s = 3, we get A140996 (e = 0) and A140995 (e = 1). For s = 4, we have array A141020 (with e = 0) and the current array (with e = 1). In some of these arrays, the indices n and k are sometimes shifted.
Putting k = 1 in Stepan's triangles with index of asymmetry s and index of obliqueness e = 0, we get G(n + s + 2, 1) = 1 + Sum_{1 <= m <= s+1} G(n+m, 1) for n >= 0 and k = 1..(n+1) with initial conditions G(x+1, 1) = 2^x for x = 0..s. Thus, we get a shifted version of column s+1 in array A172119. These sequences were first studied by Dunkel (1925).
Thus, the second main diagonal of Stepan's triangles with index of asymmetry s and index of obliqueness e = 1 is equal to a shifted version of column s + 1 in array A172119.
It follows from Eq. (20) on p. 360 in Dunkel (1925) that, for Stepan's triangles with index of asymmetry s and index of obliqueness e = 0, we have G(n, 1) = Sum_{t = 1..floor((n + s + 1)/(s + 2))} (-1)^(t + 1) * binomial(n + s - t*(s + 1), t - 1) * 2^(n + s - t*(s + 2) + 1) for n >= 0.
In a similar way, for Stepan's triangles with index of asymmetry s and index of obliqueness e = 1, we have G(n, n - 1) = Sum_{t = 1..floor((n + s + 1)/(s + 2))} (-1)^(t + 1) * binomial(n + s - t*(s + 1), t - 1) * 2^(n + s - t*(s + 2) + 1) for n >= 1.
Let A_s(x, y) be the bivariate g.f. of G(n, k) with index of asymmetry s and index of obliqueness e = 0 and let B_s(x, y) be the bivariate g.f. of the other G(n, k) with index of asymmetry s and index of obliqueness e = 1. Because the two triangular arrays are mirror images of each other, we have B_s(x, y) = A_s(x*y, y^(-1)).
(End)

Examples

			Pascal-like triangle with y = 4 and z = 1 (with rows n >= 0 and columns k >= 0) begins as follows:
  1
  1 1
  1 2 1
  1 2 4 1
  1 2 4 8  1
  1 2 4 8 16  1
  1 2 4 8 16 32  1
  1 2 4 8 16 33 63   1
  1 2 4 8 16 33 67 124   1
  1 2 4 8 16 33 67 136 244   1
  1 2 4 8 16 33 67 136 276 480   1
  1 2 4 8 16 33 67 136 276 560 944 1
  ...
		

Crossrefs

Programs

  • Maple
    # This is a slight modification of R. J. Mathar's Maple program from array A141020:
    A141020 := proc(n, k) option remember ; if k<0 or k>n then 0 ; elif k=0 or k=n then 1 ; elif k=n-1 then 2 ; elif k=n-2 then 4 ; elif k=n-3 then 8 ; elif k=n-4 then 16 ; else procname(n-1, k) +procname(n-2, k)+procname(n-3, k)+procname(n-4, k) +procname(n-5, k)+procname(n-5, k-1) ; fi; end:
    A141021 := proc(n, k) A141020(n, n-k): end:
    for n1 from 0 to 20 do for k1 from 0 to n1 do printf("%d, ", A141021(n1, k1)) ; od: od: # Petros Hadjicostas, Jun 16 2019
  • Mathematica
    t[n_, k_] := t[n, k] = Which[k < 0 || k > n, 0, k == 0 || k == n, 1, k == n - 1, 2, k == n - 2, 4, k == n - 3, 8, k == n - 4, 16, True, t[n - 1, k] + t[n - 2, k] + t[n - 3, k] + t[n - 4, k] + t[n - 5, k] + t[n - 5, k - 1]];
    T[n_, k_] := t[n, n - k];
    Table[Table[T[n, k], {k, 0, n}], {n, 0, 10}] // Flatten (* Jean-François Alcover, Apr 24 2020 *)

Formula

T(n, k) = A141020(n, n-k). - R. J. Mathar, Sep 19 2008
From Petros Hadjicostas, Jun 16 2019: (Start)
Recurrence: G(n+6, k) = G(n+1, k-4) + G(n+1, k-5) + G(n+2, k-4) + G(n+3, k-3) + G(n+4, k-2) + G(n+5, k-1) for n >= 0 and k = 5..(n+5) with G(n+x+1, x) = 2^x for x = 0..4 and n >= 0.
Bivariate g.f.: Sum_{n,k >=0} T(n, k)*x^n*y^k = (x^6*y^5 - x^5*y^5 - x^4*y^4 + x^4*y^3 - x^3*y^3 + x^3*y^2 - x^2*y^2 + x^2*y - x*y + 1)/((1 - x*y) * (1 - x) * (1 - x*y - x^2*y^2 - x^3*y^3 - x^4*y^4 - x^5*y^4 - x^5*y^5)).
Second main diagonal: G(n, n - 1) = Sum_{t = 1..floor((n + 5)/6)} (-1)^(t + 1) * binomial(n + 4 - 5*t, t - 1) * 2^(n + 5 - 6*t) for n >= 1.
Limiting row: Let b(k) = lim_{n -> infinity} G(n, k) for k >= 0. Then b(k) = b(k-5) + 2*b(k-4) + b(k-3) + b(k-2) + b(k-1) for k >= 5 with b(x) = 2^x for x = 0..4. This is the sequence 1, 2, 4, 8, 16, 33, 67, 136, 276, 561, 1140, 2316, 4705, 9559, 19421, 39457, 80163, 162864, 330885, 672247, ..., which is A308808.
(End)

Extensions

Partially edited by N. J. A. Sloane, Jul 18 2008
Comment simplified by R. J. Mathar, Sep 19 2008
Data corrected by Jean-François Alcover, Apr 24 2020

A141020 Pascal-like triangle with index of asymmetry y = 4 and index of obliqueness z = 0.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 2, 1, 1, 8, 4, 2, 1, 1, 16, 8, 4, 2, 1, 1, 32, 16, 8, 4, 2, 1, 1, 63, 33, 16, 8, 4, 2, 1, 1, 124, 67, 33, 16, 8, 4, 2, 1, 1, 244, 136, 67, 33, 16, 8, 4, 2, 1, 1, 480, 276, 136, 67, 33, 16, 8, 4, 2, 1, 1, 944, 560, 276, 136, 67, 33, 16, 8, 4, 2, 1
Offset: 0

Views

Author

Juri-Stepan Gerasimov, Jul 11 2008

Keywords

Comments

The left column is set to 1. The four rightmost columns start with powers of 2:
T(n, 0) = T(n, n)=1; T(n, n-1)=2; T(n, n-2)=4; T(n, n-3)=8; T(n, n-4)=16.
Recurrence: T(n, k) = T(n-1, k) + T(n-2, k) + T(n-3, k) + T(n-4, k) + T(n-5, k) + T(n-5,k-1), k = 1..n-5.
From Petros Hadjicostas, Jun 14 2019: (Start)
In the attached photograph we see that the index of asymmetry is denoted by s (rather than y) and the index of obliqueness by e (rather than z).
The general recurrence is G(n+s+2, k) = G(n+1, k-e*s+e-1) + Sum_{1 <= m <= s+1} G(n+m, k-e*s+m*e-2*e) for n >= 0 with k = 1..(n+1) when e = 0 and k = (s+1)..(n+s+1) when e = 1. The initial conditions are G(n+x+1, n-e*n+e*x-e+1) = 2^x for x=0..s and n >= 0. There is one more initial condition, namely, G(n, e*n) = 1 for n >= 0.
For s = 0, we get Pascal's triangle A007318. For s = 1, we get A140998 (e = 0) and A140993 (e = 1). For s = 2, we get A140997 (e = 0) and A140994 (e = 1). For s = 3, we get A140996 (e = 0) and A140995 (e = 1). For s = 4, we have the current array (with e = 0) and array A141021 (with e = 1). In some of these arrays, the indices n and k are sometimes shifted.
(End)

Examples

			Pascal-like triangle with y = 4 and z = 0 begins as follows:
  1
  1   1
  1   2   1
  1   4   2   1
  1   8   4   2   1
  1  16   8   4   2  1
  1  32  16   8   4  2  1
  1  63  33  16   8  4  2  1
  1 124  67  33  16  8  4  2 1
  1 244 136  67  33 16  8  4 2 1
  1 480 276 136  67 33 16  8 4 2 1
  1 944 560 276 136 67 33 16 8 4 2 1
  ...
		

Crossrefs

Programs

  • Maple
    A141020 := proc(n,k) option remember ; if k<0 or k>n then 0 ; elif k=0 or k=n then 1 ; elif k=n-1 then 2 ; elif k=n-2 then 4 ; elif k=n-3 then 8 ; elif k=n-4 then 16 ; else procname(n-1,k) +procname(n-2,k)+procname(n-3,k)+procname(n-4,k) +procname(n-5,k)+procname(n-5,k-1) ; fi; end:
    for n from 0 to 20 do for k from 0 to n do printf("%d,",A141020(n,k)) ; od: od: # R. J. Mathar, Sep 19 2008
  • Mathematica
    T[n_, k_] := T[n, k] = Which[k < 0 || k > n, 0, k == 0 || k == n, 1, k == n-1, 2, k == n-2, 4, k == n-3, 8, k == n-4, 16, True, T[n-1, k] + T[n-2, k] + T[n-3, k] + T[n-4, k] + T[n-5, k] + T[n-5, k-1]];
    Table[T[n, k], {n, 0, 11}, {k, 0, n}] // Flatten (* Jean-François Alcover, Dec 18 2019, after R. J. Mathar *)

Formula

From Petros Hadjicostas, Jun 14 2019: (Start)
T(n, k) = A141021(n, n-k) for 0 <= k <= n.
Bivariate g.f.: Sum_{n,k >= 0} T(n, k)*x^n*y^k = (1 - x - x^2 - x^3 - x^4 - x^5 + y*x^2*(1 + x + x^2 + x^4)) / ((1 - x) * (1 - x*y) * (1 - x - x^2 - x^3 - x^4 - x^5 - x^5*y)).
Differentiating the bivariate w.r.t. y and setting y = 0, we get the g.f. of the column k = 1: x/((-1 + x)*(x^5 + x^4 + x^3 + x^2 + x - 1)). This is the g.f. of a shifted version of sequence A001949.
(End)

Extensions

Partially edited by N. J. A. Sloane, Jul 18 2008
Recurrence rewritten by R. J. Mathar, Sep 19 2008

A141066 List of different composites in Pascal-like triangles with index of asymmetry y = 2 and index of obliquity z = 0 or z = 1.

Original entry on oeis.org

4, 8, 9, 15, 28, 40, 52, 96, 88, 170, 177, 188, 326, 345, 189, 400, 600, 694, 406, 846, 1104, 1386, 871, 1779, 2031, 2751, 872, 1866, 3736, 6872, 7730, 10672, 4022, 8505, 12640, 15979, 20885, 4023, 8633, 18079, 23249, 32859, 40724, 42762, 67240, 18559, 39677, 78652, 80866, 153402
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jul 14 2008

Keywords

Comments

For the Pascal-like triangle G(n, k) with index of asymmetry y = 2 and index of obliqueness z = 0, which is read by rows, we have G(n, 0) = G(n+1, n+1) = 1, G(n+2, n+1) = 2, G(n+3, n+1) = 4, G(n+4, k) = G(n+1, k-1) + G(n+1, k) + G(n+2, k) + G(n+3, k) for k = 1..(n+1). (This is array A140997.)
For the Pascal-like triangle with index of asymmetry y = 1 and index of obliqueness z = 1, which is read by rows, we have G(n, n) = G(n+1, 0) = 1, G(n+2, 1) = 2, G(n+3, 2) = 4, G(n+4, k) = G(n+1, k-2) + G(n+1, k-3) + G(n+2, k-2) + G(n+3, k-1) for k = 3..(n+3). (This is array A140994.)
From Petros Hadjicostas, Jun 12 2019: (Start)
The two triangular arrays A140997 and A140994, which are described above, are mirror images of each other.
To make the current sequence uniquely defined, we follow the suggestion of R. J. Mathar for sequence A141064. For each row of array A140997, the composites not appearing in earlier rows are collected, sorted, and added to the sequence. We get exactly the same sequence by working with array A140994 instead.
Finally, we mention that in the attached picture about the connection between Stepan's triangles and the Pascal triangle, the letter s is used to describe the index of asymmetry and the letter e is used to describe the index of obliqueness (instead of the letters y and z, respectively). The Pascal triangle A007318 has index of asymmetry s = y = 0 (and it does not matter whether we use e = 0 or e = 1 in the general formulas in the attached photograph).
(End)

Examples

			Pascal-like triangle with y = 2 and z = 0 (i.e., A140997) begins as follows:
  1, so no composite.
  1 1, so no composite.
  1 2 1, so no composite.
  1 4 2 1, so a(1) = 4.
  1 8 4 2 1, so a(2) = 8.
  1 15 9 4 2 1, so a(3) = 9 and a(4) = 15.
  1 28 19 9 4 2 1, so a(5) = 28.
  1 52 40 19 9 4 2 1, so a(6) = 40 and a(7) = 52.
  1 96 83 41 19 9 4 2 1, so a(8) = 96.
  1 177 170 88 41 19 9 4 2 1, so a(9) = 88, a(10) = 170, and a(11) = 177.
  1 326 345 188 88 41 19 9 4 2 1, so a(12) = 188, a(13) = 326, and a(14) = 345.
  1 600 694 400 189 88 41 19 9 4 2 1, so a(15) = 189, a(16) = 400, a(17) = 600, and a(18) = 694.
... [example edited by _Petros Hadjicostas_, Jun 11 2019]
		

Crossrefs

Cf. A007318 (y = 0), A140993 (y = 1 and z = 1), A140994 (y = 2 and z = 1), A140995 (y = 3 and z = 1), A140996 (y = 3 and z = 0), A140997 (y = 2 and z = 0), A140998 (y = 1 and z = 0), A141020 (y = 4 and z = 0), A141021 (y = 4 and z = 1), A141064 (has primes when y = 1), A141065 (has composites when y = 1), A141067 (has primes when y = 2), A141068 (has primes when y = 3), A141069 (has composites when y = 3).

Programs

  • Maple
    # This is a modification of R. J. Mathar's program for A141031 (for the case y = 4 and z = 0).
    # Construction of array A140997 (y = 2 and z = 0):
    A140997 := proc(n, k) option remember; if k < 0 or n < k then 0; elif k = 0 or k = n then 1; elif k = n - 1 then 2; elif k = n - 2 then 4; else procname(n - 1, k) + procname(n - 2, k) + procname(n - 3, k) + procname(n - 3, k - 1); end if; end proc;
    # Construction of the current sequence:
    A141066 := proc(nmax) local a, b, n, k, new; a := []; for n from 0 to nmax do b := []; for k from 0 to n do new := A140997(n, k); if not (new = 1 or isprime(new) or new in a or new in b) then b := [op(b), new]; end if; end do; a := [op(a), op(sort(b))]; end do; RETURN(a); end proc;
    # Generation of numbers in the current sequence:
    A141066(19);
    # If one wishes to sort the numbers, then replace RETURN(a) with RETURN(sort(a)) in the above Maple code. In this case, however, the sequence is not uniquely defined because it depends on the maximum n. - Petros Hadjicostas, Jun 15 2019

Extensions

Partially edited by N. J. A. Sloane, Jul 18 2008
Comments and Example edited by Petros Hadjicostas, Jun 12 2019
More terms from Petros Hadjicostas, Jun 12 2019
Showing 1-10 of 23 results. Next