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.

Previous Showing 11-20 of 66 results. Next

A126890 Triangle read by rows: T(n,k) = n*(n+2*k+1)/2, 0 <= k <= n.

Original entry on oeis.org

0, 1, 2, 3, 5, 7, 6, 9, 12, 15, 10, 14, 18, 22, 26, 15, 20, 25, 30, 35, 40, 21, 27, 33, 39, 45, 51, 57, 28, 35, 42, 49, 56, 63, 70, 77, 36, 44, 52, 60, 68, 76, 84, 92, 100, 45, 54, 63, 72, 81, 90, 99, 108, 117, 126, 55, 65, 75, 85, 95, 105, 115, 125, 135, 145, 155, 66, 77, 88
Offset: 0

Views

Author

Reinhard Zumkeller, Dec 30 2006

Keywords

Comments

T(n,k) + T(n,n-k) = A014105(n);
row sums give A059270; Sum_{k=0..n-1} T(n,k) = A000578(n);
central terms give A007742; T(2*n+1,n) = A016754(n);
T(n,0) = A000217(n);
T(n,1) = A000096(n) for n > 0;
T(n,2) = A055998(n) for n > 1;
T(n,3) = A055999(n) for n > 2;
T(n,4) = A056000(n) for n > 3;
T(n,5) = A056115(n) for n > 4;
T(n,6) = A056119(n) for n > 5;
T(n,7) = A056121(n) for n > 6;
T(n,8) = A056126(n) for n > 7;
T(n,10) = A101859(n-1) for n > 9;
T(n,n-3) = A095794(n-1) for n > 2;
T(n,n-2) = A045943(n-1) for n > 1;
T(n,n-1) = A000326(n) for n > 0;
T(n,n) = A005449(n).

Examples

			From _Philippe Deléham_, Oct 03 2011: (Start)
Triangle begins:
   0;
   1,  2;
   3,  5,  7;
   6,  9, 12, 15;
  10, 14, 18, 22, 26;
  15, 20, 25, 30, 35, 40;
  21, 27, 33, 39, 45, 51, 57;
  28, 35, 42, 49, 56, 63, 70, 77; (End)
		

References

  • Léonard Euler, Introduction à l'analyse infinitésimale, tome premier, ACL-Editions, Paris, 1987, p. 353-354.

Crossrefs

Cf. A110449.

Programs

  • Haskell
    a126890 n k = a126890_tabl !! n !! k
    a126890_row n = a126890_tabl !! n
    a126890_tabl = map fst $ iterate
       (\(xs@(x:_), i) -> (zipWith (+) ((x-i):xs) [2*i+1 ..], i+1)) ([0], 0)
    -- Reinhard Zumkeller, Nov 10 2013
  • Mathematica
    Flatten[Table[(n(n+2k+1))/2,{n,0,20},{k,0,n}]] (* Harvey P. Dale, Jun 21 2013 *)

Formula

T(n,k) = T(n,k-1) + n, for k <= n. - Philippe Deléham, Oct 03 2011

A095660 Pascal (1,3) triangle.

Original entry on oeis.org

3, 1, 3, 1, 4, 3, 1, 5, 7, 3, 1, 6, 12, 10, 3, 1, 7, 18, 22, 13, 3, 1, 8, 25, 40, 35, 16, 3, 1, 9, 33, 65, 75, 51, 19, 3, 1, 10, 42, 98, 140, 126, 70, 22, 3, 1, 11, 52, 140, 238, 266, 196, 92, 25, 3, 1, 12, 63, 192, 378, 504, 462, 288, 117, 28, 3, 1, 13, 75, 255, 570, 882, 966, 750, 405, 145, 31, 3
Offset: 0

Views

Author

Wolfdieter Lang, May 21 2004

Keywords

Comments

This is the third member, q=3, in the family of (1,q) Pascal triangles: A007318 (Pascal (q=1)), A029635 (q=2) (but with T(0,0)=2, not 1).
This is an example of a Riordan triangle (see A053121 for a comment and the 1991 Shapiro et al. reference on the Riordan group) with o.g.f. of column no. m of the type g(x)*(x*f(x))^m with f(0)=1. Therefore the o.g.f. for the row polynomials p(n,x) = Sum_{m=0..n} T(n,m)*x^m is G(z,x) = g(z)/(1-x*z*f(z)). Here: g(x) = (3-2*x)/(1-x), f(x) = 1/(1-x), hence G(z,x) = (3-2*z)/(1-(1+x)*z).
The SW-NE diagonals give Sum_{k=0..ceiling((n-1)/2)} T(n-1-k,k) = A000285(n-2), n>=2, with n=1 value 3. Observation by Paul Barry, Apr 29 2004. Proof via recursion relations and comparison of inputs.
Central terms: T(2*n,n) = A028329(n) = A100320(n) for n > 0, A028329 are the central terms of triangle A028326. - Reinhard Zumkeller, Apr 08 2012
Let P be Pascal's triangle, A007318 and R the Riordan array, A097805. Then Pascal triangle (1,q) = ((q-1) * R) + P. Example: Pascal triangle (1,3) = (2 * R) + P. - Gary W. Adamson, Sep 12 2015

Examples

			Triangle starts:
  3;
  1,  3;
  1,  4,  3;
  1,  5,  7,   3;
  1,  6, 12,  10,   3;
  1,  7, 18,  22,  13,   3;
  1,  8, 25,  40,  35,  16,   3;
  1,  9, 33,  65,  75,  51,  19,   3;
  1, 10, 42,  98, 140, 126,  70,  22,   3;
  1, 11, 52, 140, 238, 266, 196,  92,  25,   3;
  1, 12, 63, 192, 378, 504, 462, 288, 117,  28,  3;
  1, 13, 75, 255, 570, 882, 966, 750, 405, 145, 31, 3;
		

Crossrefs

Row sums: A000079(n+1), n>=1, 3 if n=0. Alternating row sums are [3, -2, followed by 0's].
Column sequences (without leading zeros) give for m=1..9 with n>=0: A000027(n+3), A055998(n+1), A006503(n+1), A095661, A000574, A095662, A095663, A095664, A095665.
Cf. A097805.

Programs

  • Haskell
    a095660 n k = a095660_tabl !! n !! k
    a095660_row n = a095660_tabl !! n
    a095660_tabl = [3] : iterate
       (\row -> zipWith (+) ([0] ++ row) (row ++ [0])) [1,3]
    -- Reinhard Zumkeller, Apr 08 2012
    
  • Magma
    A095660:= func< n,k | n eq 0 select 3 else (1+2*k/n)*Binomial(n,k) >;
    [A095660(n,k): k in [0..n], n in [1..12]]; // G. C. Greubel, May 02 2021
    
  • Maple
    T(n,k):=piecewise(n=0,3,0Mircea Merca, Apr 08 2012
  • Mathematica
    {3}~Join~Table[(1 + 2 k/n) Binomial[n, k], {n, 11}, {k, 0, n}] // Flatten (* Michael De Vlieger, Sep 14 2015 *)
  • Sage
    def A095660(n,k): return 3 if n==0 else (1+2*k/n)*binomial(n,k)
    flatten([[A095660(n,k) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, May 02 2021

Formula

Recursion: T(n, m)=0 if m>n, T(0, 0)= 3; T(n, 0)=1 if n>=1; T(n, m) = T(n-1, m) + T(n-1, m-1).
G.f. column m (without leading zeros): (3-2*x)/(1-x)^(m+1), m>=0.
T(n,k) = (1+2*k/n) * binomial(n,k), for n>0. - Mircea Merca, Apr 08 2012
Closed-form formula for arbitrary left and right borders of Pascal like triangle see A228196. - Boris Putievskiy, Aug 19 2013

A185787 Sum of first k numbers in column k of the natural number array A000027; by antidiagonals.

Original entry on oeis.org

1, 7, 25, 62, 125, 221, 357, 540, 777, 1075, 1441, 1882, 2405, 3017, 3725, 4536, 5457, 6495, 7657, 8950, 10381, 11957, 13685, 15572, 17625, 19851, 22257, 24850, 27637, 30625, 33821, 37232, 40865, 44727, 48825, 53166, 57757, 62605, 67717, 73100, 78761, 84707, 90945, 97482, 104325, 111481, 118957, 126760, 134897, 143375
Offset: 1

Views

Author

Clark Kimberling, Feb 03 2011

Keywords

Comments

This is one of many interesting sequences and arrays that stem from the natural number array A000027, of which a northwest corner is as follows:
1....2.....4.....7...11...16...22...29...
3....5.....8....12...17...23...30...38...
6....9....13....18...24...31...39...48...
10...14...19....25...32...40...49...59...
15...20...26....33...41...50...60...71...
21...27...34....42...51...61...72...84...
28...35...43....52...62...73...85...98...
Blocking out all terms below the main diagonal leaves columns whose sums comprise A185787. Deleting the main diagonal and then summing give A185787. Analogous treatments to the left of the main diagonal give A100182 and A101165. Further sequences obtained directly from this array are easily obtained using the following formula for the array: T(n,k)=n+(n+k-2)(n+k-1)/2.
Examples:
row 1: A000124
row 2: A022856
row 3: A016028
row 4: A145018
row 5: A077169
col 1: A000217
col 2: A000096
col 3: A034856
col 4: A055998
col 5: A046691
col 6: A052905
col 7: A055999
diag. (1,5,...) ...... A001844
diag. (2,8,...) ...... A001105
diag. (4,12,...)...... A046092
diag. (7,17,...)...... A056220
diag. (11,23,...) .... A132209
diag. (16,30,...) .... A054000
diag. (22,38,...) .... A090288
diag. (3,9,...) ...... A058331
diag. (6,14,...) ..... A051890
diag. (10,20,...) .... A005893
diag. (15,27,...) .... A097080
diag. (21,35,...) .... A093328
antidiagonal sums: (1,5,15,34,...)=A006003=partial sums of A002817.
Let S(n,k) denote the n-th partial sum of column k. Then
S(n,k)=n*(n^2+3k*n+3*k^2-6*k+5)/6.
S(n,1)=n(n+1)(n+2)/6
S(n,2)=n(n+1)(n+5)/6
S(n,3)=n(n+2)(n+7)/6
S(n,4)=n(n^2+12n+29)/6
S(n,5)=n(n+5)(n+10)/6
S(n,6)=n(n+7)(n+11)/6
S(n,7)=n(n+10)(n+11)/6
Weight array of T: A144112
Accumulation array of T: A185506
Second rectangular sum array of T: A185507
Third rectangular sum array of T: A185508
Fourth rectangular sum array of T: A185509

Crossrefs

Programs

  • Magma
    [n*(7*n^2-6*n+5)/6: n in [1..50]]; // Vincenzo Librandi, Jul 04 2012
  • Mathematica
    f[n_,k_]:=n+(n+k-2)(n+k-1)/2;
    s[k_]:=Sum[f[n,k],{n,1,k}];
    Factor[s[k]]
    Table[s[k],{k,1,70}]  (* A185787 *)
    CoefficientList[Series[(3*x^2+3*x+1)/(1-x)^4,{x,0,50}],x] (* Vincenzo Librandi, Jul 04 2012 *)

Formula

a(n)=n*(7*n^2-6*n+5)/6.
G.f.: x*(3*x^2+3*x+1)/(1-x)^4. - Vincenzo Librandi, Jul 04 2012

Extensions

Edited by Clark Kimberling, Feb 25 2023

A059438 Triangle T(n,k) (1 <= k <= n) read by rows: T(n,k) is the number of permutations of [1..n] with k components.

Original entry on oeis.org

1, 1, 1, 3, 2, 1, 13, 7, 3, 1, 71, 32, 12, 4, 1, 461, 177, 58, 18, 5, 1, 3447, 1142, 327, 92, 25, 6, 1, 29093, 8411, 2109, 531, 135, 33, 7, 1, 273343, 69692, 15366, 3440, 800, 188, 42, 8, 1, 2829325, 642581, 125316, 24892, 5226, 1146, 252, 52, 9, 1
Offset: 1

Views

Author

N. J. A. Sloane, Feb 01 2001

Keywords

Examples

			Triangle begins:
[1] [     1]
[2] [     1,     1]
[3] [     3,     2,     1]
[4] [    13,     7,     3,    1]
[5] [    71,    32,    12,    4,   1]
[6] [   461,   177,    58,   18,   5,   1]
[7] [  3447,  1142,   327,   92,  25,   6,  1]
[8] [ 29093,  8411,  2109,  531, 135,  33,  7, 1]
[9] [273343, 69692, 15366, 3440, 800, 188, 42, 8, 1]
		

Crossrefs

A version with reflected rows is A263484.
Diagonals give A003319, A059439, A059440, A055998.
T(2n,n) gives A308650.

Programs

  • Maple
    # Uses function PMatrix from A357368. Adds column 1, 0, 0, ... to the left.
    PMatrix(10, A003319); # Peter Luschny, Oct 09 2022
  • Mathematica
    (* p = indecomposable permutations = A003319 *) p[n_] := p[n] = n! - Sum[ k!*p[n-k], {k, 1, n-1}]; t[n_, k_] /; n < k = 0; t[n_, 1] := p[n]; t[n_, k_] /; n >= k := t[n, k] = Sum[ t[n-j, k-1]*p[j], {j, 1, n}]; Flatten[ Table[ t[n, k], {n, 1, 10}, {k, 1, n}] ] (* Jean-François Alcover, Mar 06 2012, after Philippe Deléham *)
  • SageMath
    def A059438_triangle(dim) :
        R = PolynomialRing(ZZ, 'x')
        C = [R(0)] + [R(1) for i in range(dim+1)]
        A = [(i + 2) // 2 for i in range(dim+1)]
        A[0] = R.gen(); T = []
        for k in range(1, dim+1) :
            for n in range(k, 0, -1) :
                C[n] = C[n-1] + C[n+1] * A[n-1]
            T.append(list(C[1])[1::])
        return T
    A059438_triangle(8) # Peter Luschny, Sep 10 2022
    
  • SageMath
    # Alternatively, using the function PartTrans from A357078:
    # Adds a (0,0)-based column (1, 0, 0, ...) to the left of the triangle.
    dim = 10
    A = ZZ[['t']]; g = A([0]+[factorial(n) for n in range(1, 30)]).O(dim+2)
    PartTrans(dim, lambda n: list(g / (1 +  g))[n]) # Peter Luschny, Sep 11 2022

Formula

Let f(x) = Sum_{n >= 0} n!*x^n, g(x) = 1 - 1/f(x). Then g(x) is g.f. for first diagonal A003319 and Sum_{n >= k} T(n, k)*x^n = g(x)^k.
Triangle T(n, k), n > 0 and k > 0, read by rows; given by [0, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, ...] DELTA A000007 where DELTA is Deléham's operator defined in A084938.
T(n+k, k) = Sum_{a_1 + a_2 + ... + a_k = n} A003319(a_1)*A003319(a_2)*...*A003319(a_k). T(n, k) = 0 if n < k, T(n, 1) = A003319(n) and for n >= k T(n, k)= Sum_{j>=1} T(n-j, k-1)* A003319(j). A059438 is formed from the self convolution of its first column (A003319). - Philippe Deléham, Feb 04 2004
Sum_{k>0} T(n, k) = n!; see A000142. - Philippe Deléham, Feb 05 2004
If g(x) = x + x^2 + 3*x^3 + 13*x^4 + ... is the generating function for the number of permutations with no global descents, then 1/(1-g(x)) is the generating function for n!. Setting t=1 in f(x, t) implies Sum_{k=1..n} T(n,k) = n!. Let g(x) be the o.g.f. for A003319. Then the o.g.f. for this table is given by f(x, t) = 1/(1 - t*g(x)) - 1 (i.e., the coefficient of x^n*t^k in f(x,t) is T(n,k)). - Mike Zabrocki, Jul 29 2004

Extensions

More terms from Vladeta Jovovic, Mar 04 2001

A111774 Numbers that can be written as a sum of at least three consecutive positive integers.

Original entry on oeis.org

6, 9, 10, 12, 14, 15, 18, 20, 21, 22, 24, 25, 26, 27, 28, 30, 33, 34, 35, 36, 38, 39, 40, 42, 44, 45, 46, 48, 49, 50, 51, 52, 54, 55, 56, 57, 58, 60, 62, 63, 65, 66, 68, 69, 70, 72, 74, 75, 76, 77, 78, 80, 81, 82, 84, 85, 86, 87, 88, 90, 91, 92, 93, 94, 95, 96, 98, 99, 100, 102
Offset: 1

Views

Author

Jaap Spies, Aug 15 2005

Keywords

Comments

In this sequence there are no (odd) primes and there are no powers of 2.
So we have only three kinds of natural numbers: the odd primes, the powers of 2 and the numbers that can be represented as a sum of at least three consecutive integers.
Odd primes can only be written as a sum of two consecutive integers. Powers of 2 do not have a representation as a sum of k consecutive integers (other than the trivial n=n, for k=1).
Numbers of the form (x*(x+1)-y*(y+1))/2 for nonnegative integers x,y with x-y >= 3. - Bob Selcoe, Feb 21 2014
Numbers of the form (x + 1)*(x + 2*y)/2 for integers x,y with x >= 2 and y >= 1. For y = 1 only triangular numbers (A000217) >= 6 occur. - Ralf Steiner, Jun 27 2019
From Ralf Steiner, Jul 09 2019: (Start)
If k >= 1 sequences are c_k(n) = c_k(n - 1) + n + k - 1, c_k(0) = 0, means c_k(n) = n*(n + 2*k - 1)/2: A000217, A000096, A055998, A055999, A056000, ... then this sequence is the union of c_k(n), n >= 3. (End)
From Wolfdieter Lang, Oct 28 2020: (Start)
This sequence gives all positive integers that have at least one odd prime as proper divisor. The proof follows from the first two comments.
The set {a(n)}_{n>=1} equals the set {k positive integer : floor(k/2) - delta(k) >= 1}, where delta(k) = A055034(k). Proof: floor(k/2) gives the number of positive odd numbers < k, and delta(k), gives the number of positive odd numbers coprime to k. delta(1) = 1 but 1 is not < 1, therefore k = 1 is not a member of this set. Hence a member >= 2 of this set has at least one odd number > 1 and < k missing in the set of odd numbers relative prime to k. Therefore there exists at least one odd prime < k dividing k. (End)
For the multiplicity of a(n) see A338428, obtained from triangle A337940 (the array is given Bob Selcoe as example below, and in the Ralf Steiner comment above). - Wolfdieter Lang, Dec 09 2020

Examples

			a(1)=6 because 6 is the first number that can be written as a sum of three consecutive positive integers: 6 = 1+2+3.
From _Bob Selcoe_, Feb 23 2014: (Start)
Let the top row of an array be A000217(n). Let the diagonals (reading down and left) be A000217(n)-A000217(1),  A000217(n)-A000217(2), A000217(n)-A000217(3)..., A000217(n)-A000217(n-3).  This is A049777 read as a square array, starting with the third column. The array begins as follows:
   6 10 15 21 28 36 45 55 66
   9 14 20 27 35 44 54 65
  12 18 25 33 42 52 63
  15 22 30 39 49 60
  18 26 35 45 56
  21 30 40 51
  24 34 45
  27 38
  30
This is (x*(x+1)-y*(y+1))/2 for nonnegative integers x,y with x-y >= 3, because it is equivalent to 1+2+3/+4/+5/...+x/-0/-1/-2/-3/-4/-5/...-(x+3)/ for all possible strings of consecutive integers, which represents every possible way to sum three or more consecutive positive integers. So for example, 4+5+6+7 = 1+2+3+4+5+6+7-1-2-3 = 22, which is (x*(x+1)-y*(y+1))/2 when x=7, y=3. Notice that values can appear more than once in the array because some numbers can be represented as sums of more than one string of three or more consecutive positive integers. For example, 30 = (x*(x+1)-y*(y+1))/2 when (a) x=11, y=8: 9+10+11; (b) x=9, y=5: 6+7+8+9; and (c) x=8, y=3: 4+5+6+7+8. By definition, x-y is the number of integers in the string. (End)
		

References

  • Paul Halmos, "Problems for Mathematicians, Young and Old", Dolciani Mathematical Expositions, 1991, Solution to problem 3G p. 179.

Crossrefs

Programs

  • Maple
    ispoweroftwo := proc(n) local a, t; t := 1; while (n > t) do t := 2*t end do; if (n = t) then a := true else a := false end if; return a; end proc; f:= proc(n) if (not isprime(n)) and (not ispoweroftwo(n)) then return n end if; end proc; seq(f(i),i = 1..150);
  • Mathematica
    max=6!;lst={};Do[z=n+(n+1);Do[z+=(n+x);If[z>max,Break[]];AppendTo[lst,z],{x,2,max}],{n,max}];Union[lst] (* Vladimir Joseph Stephan Orlovsky, Mar 06 2010 *)
  • PARI
    isok(n) = !(n == 1) && !isprime(n) && !(isprimepower(n, &p) && (p == 2)); \\ Michel Marcus, Jul 02 2019
    
  • Python
    from sympy import primepi
    def A111774(n):
        def f(x): return int(n+(0 if x<=1 else primepi(x)-1)+x.bit_length())
        m, k = n, f(n)
        while m != k: m, k = k, f(k)
        return m # Chai Wah Wu, Sep 19 2024

A179986 Second 9-gonal (or nonagonal) numbers: a(n) = n*(7*n+5)/2.

Original entry on oeis.org

0, 6, 19, 39, 66, 100, 141, 189, 244, 306, 375, 451, 534, 624, 721, 825, 936, 1054, 1179, 1311, 1450, 1596, 1749, 1909, 2076, 2250, 2431, 2619, 2814, 3016, 3225, 3441, 3664, 3894, 4131, 4375, 4626, 4884, 5149, 5421, 5700, 5986, 6279, 6579, 6886
Offset: 0

Views

Author

Bruno Berselli, Jan 13 2011

Keywords

Comments

This sequence is a bisection of A118277 (even part).
Sequence found by reading the line from 0, in the direction 0, 19... and the line from 6, in the direction 6, 39,..., in the square spiral whose vertices are the generalized 9-gonal numbers A118277. - Omar E. Pol, Jul 24 2012
The early part of this sequence is a strikingly close approximation to the early part of A100752. - Peter Munn, Nov 14 2019

Crossrefs

Cf. second k-gonal numbers: A005449 (k=5), A014105 (k=6), A147875 (k=7), A045944 (k=8), this sequence (k=9), A033954 (k=10), A062728 (k=11), A135705 (k=12).

Programs

Formula

G.f.: x*(6 + x)/(1 - x)^3.
a(n) = Sum_{i=0..(n-1)} A017053(i) for n>0.
a(-n) = A001106(n).
Sum_{i=0..n} (a(n)+i)^2 = ( Sum_{i=(n+1)..2*n} (a(n)+i)^2 ) + 21*A000217(n)^2 for n>0.
a(n) = a(n-1)+7*n-1 for n>0, with a(0)=0. - Vincenzo Librandi, Feb 05 2011
a(0)=0, a(1)=6, a(2)=19; for n>2, a(n) = 3*a(n-1)-3*a(n-2)+a(n-3). - Harvey P. Dale, Aug 19 2011
a(n) = A174738(7n+5). - Philippe Deléham, Mar 26 2013
a(n) = A001477(n) + 2*A000290(n) + 3*A000217(n). - J. M. Bergot, Apr 25 2014
a(n) = A055998(4*n) - A055998(3*n). - Bruno Berselli, Sep 23 2016
E.g.f.: (x/2)*(12 + 7*x)*exp(x). - G. C. Greubel, Aug 19 2017

A255961 Square array A(n,k), n>=0, k>=0, read by antidiagonals, where column k is Euler transform of (j->j*k).

Original entry on oeis.org

1, 1, 0, 1, 1, 0, 1, 2, 3, 0, 1, 3, 7, 6, 0, 1, 4, 12, 18, 13, 0, 1, 5, 18, 37, 47, 24, 0, 1, 6, 25, 64, 111, 110, 48, 0, 1, 7, 33, 100, 215, 303, 258, 86, 0, 1, 8, 42, 146, 370, 660, 804, 568, 160, 0, 1, 9, 52, 203, 588, 1251, 1938, 2022, 1237, 282, 0
Offset: 0

Views

Author

Alois P. Heinz, Mar 11 2015

Keywords

Comments

A(n,k) is the number of partitions of n when parts i are of k*i kinds. A(2,2) = 7: [2a], [2b], [2c], [2d], [1a,1a], [1a,1b], [1b,1b].

Examples

			Square array A(n,k) begins:
  1,  1,   1,    1,    1,     1,     1,     1, ...
  0,  1,   2,    3,    4,     5,     6,     7, ...
  0,  3,   7,   12,   18,    25,    33,    42, ...
  0,  6,  18,   37,   64,   100,   146,   203, ...
  0, 13,  47,  111,  215,   370,   588,   882, ...
  0, 24, 110,  303,  660,  1251,  2160,  3486, ...
  0, 48, 258,  804, 1938,  4005,  7459, 12880, ...
  0, 86, 568, 2022, 5400, 12150, 24354, 44885, ...
		

Crossrefs

Rows n=0-3 give: A000012, A001477, A055998, A101853.
Main diagonal gives A255672.
Antidiagonal sums give A299166.

Programs

  • Maple
    A:= proc(n, k) option remember; `if`(n=0, 1, k*add(
          A(n-j, k)*numtheory[sigma][2](j), j=1..n)/n)
        end:
    seq(seq(A(n, d-n), n=0..d), d=0..12);
  • Mathematica
    A[n_, k_] := A[n, k] = If[n==0, 1, k*Sum[A[n-j, k]*DivisorSigma[2, j], {j, 1, n}]/n]; Table[Table[A[n, d-n], {n, 0, d}], {d, 0, 12}] // Flatten (* Jean-François Alcover, Feb 02 2016, after Alois P. Heinz *)

Formula

G.f. of column k: Product_{j>=1} 1/(1-x^j)^(j*k).
T(n,k) = Sum_{i=0..k} C(k,i) * A257673(n,k-i).

A238858 Triangle T(n,k) read by rows: T(n,k) is the number of length-n ascent sequences with exactly k descents.

Original entry on oeis.org

1, 1, 0, 2, 0, 0, 4, 1, 0, 0, 8, 7, 0, 0, 0, 16, 33, 4, 0, 0, 0, 32, 131, 53, 1, 0, 0, 0, 64, 473, 429, 48, 0, 0, 0, 0, 128, 1611, 2748, 822, 26, 0, 0, 0, 0, 256, 5281, 15342, 9305, 1048, 8, 0, 0, 0, 0, 512, 16867, 78339, 83590, 21362, 937, 1, 0, 0, 0, 0, 1024, 52905, 376159, 647891, 307660, 35841, 594, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 06 2014

Keywords

Comments

The sequence of column k satisfies a linear recurrence with constant coefficients of order k*(k+5)/2 = A055998(k) for k>0.
T(2n,n) gives A241871(n).
Last nonzero elements of rows give A241881(n).
Row sums give A022493.

Examples

			Triangle starts:
00:     1;
01:     1,      0;
02:     2,      0,       0;
03:     4,      1,       0,       0;
04:     8,      7,       0,       0,       0;
05:    16,     33,       4,       0,       0,      0;
06:    32,    131,      53,       1,       0,      0,     0;
07:    64,    473,     429,      48,       0,      0,     0,   0;
08:   128,   1611,    2748,     822,      26,      0,     0,   0, 0;
09:   256,   5281,   15342,    9305,    1048,      8,     0,   0, 0, 0;
10:   512,  16867,   78339,   83590,   21362,    937,     1,   0, 0, 0, 0;
11:  1024,  52905,  376159,  647891,  307660,  35841,   594,   0, 0, 0, 0, 0;
12:  2048, 163835, 1728458, 4537169, 3574869, 834115, 45747, 262, 0, 0, 0, 0, 0;
...
The 53 ascent sequences of length 5 together with their numbers of descents are (dots for zeros):
01:  [ . . . . . ]   0      28:  [ . 1 1 . 1 ]   1
02:  [ . . . . 1 ]   0      29:  [ . 1 1 . 2 ]   1
03:  [ . . . 1 . ]   1      30:  [ . 1 1 1 . ]   1
04:  [ . . . 1 1 ]   0      31:  [ . 1 1 1 1 ]   0
05:  [ . . . 1 2 ]   0      32:  [ . 1 1 1 2 ]   0
06:  [ . . 1 . . ]   1      33:  [ . 1 1 2 . ]   1
07:  [ . . 1 . 1 ]   1      34:  [ . 1 1 2 1 ]   1
08:  [ . . 1 . 2 ]   1      35:  [ . 1 1 2 2 ]   0
09:  [ . . 1 1 . ]   1      36:  [ . 1 1 2 3 ]   0
10:  [ . . 1 1 1 ]   0      37:  [ . 1 2 . . ]   1
11:  [ . . 1 1 2 ]   0      38:  [ . 1 2 . 1 ]   1
12:  [ . . 1 2 . ]   1      39:  [ . 1 2 . 2 ]   1
13:  [ . . 1 2 1 ]   1      40:  [ . 1 2 . 3 ]   1
14:  [ . . 1 2 2 ]   0      41:  [ . 1 2 1 . ]   2
15:  [ . . 1 2 3 ]   0      42:  [ . 1 2 1 1 ]   1
16:  [ . 1 . . . ]   1      43:  [ . 1 2 1 2 ]   1
17:  [ . 1 . . 1 ]   1      44:  [ . 1 2 1 3 ]   1
18:  [ . 1 . . 2 ]   1      45:  [ . 1 2 2 . ]   1
19:  [ . 1 . 1 . ]   2      46:  [ . 1 2 2 1 ]   1
20:  [ . 1 . 1 1 ]   1      47:  [ . 1 2 2 2 ]   0
21:  [ . 1 . 1 2 ]   1      48:  [ . 1 2 2 3 ]   0
22:  [ . 1 . 1 3 ]   1      49:  [ . 1 2 3 . ]   1
23:  [ . 1 . 2 . ]   2      50:  [ . 1 2 3 1 ]   1
24:  [ . 1 . 2 1 ]   2      51:  [ . 1 2 3 2 ]   1
25:  [ . 1 . 2 2 ]   1      52:  [ . 1 2 3 3 ]   0
26:  [ . 1 . 2 3 ]   1      53:  [ . 1 2 3 4 ]   0
27:  [ . 1 1 . . ]   1
There are 16 ascent sequences with no descent, 33 with one, and 4 with 2, giving row 4 [16, 33, 4, 0, 0, 0].
		

Crossrefs

Cf. A137251 (ascent sequences with k ascents), A242153 (ascent sequences with k flat steps).

Programs

  • Maple
    # b(n, i, t): polynomial in x where the coefficient of x^k is   #
    #             the number of postfixes of these sequences of     #
    #             length n having k descents such that the prefix   #
    #             has rightmost element i and exactly t ascents     #
    b:= proc(n, i, t) option remember; `if`(n=0, 1, expand(add(
          `if`(ji, 1, 0)), j=0..t+1)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n, -1$2)):
    seq(T(n), n=0..12);
  • Mathematica
    b[n_, i_, t_] := b[n, i, t] = If[n == 0, 1, Sum[If[ji, 1, 0]], {j, 0, t+1}]]; T[n_] := Function[{p}, Table[Coefficient[p, x, i], {i, 0, n}]][b[n, -1, -1]]; Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, Jan 06 2015, translated from Maple *)
  • Sage
    # Transcription of the Maple program
    R. = QQ[]
    @CachedFunction
    def b(n,i,t):
        if n==0: return 1
        return sum( ( x if ji) ) for j in range(t+2) )
    def T(n): return b(n, -1, -1)
    for n in range(0,10): print(T(n).list())

A226492 a(n) = n*(11*n-5)/2.

Original entry on oeis.org

0, 3, 17, 42, 78, 125, 183, 252, 332, 423, 525, 638, 762, 897, 1043, 1200, 1368, 1547, 1737, 1938, 2150, 2373, 2607, 2852, 3108, 3375, 3653, 3942, 4242, 4553, 4875, 5208, 5552, 5907, 6273, 6650, 7038, 7437, 7847, 8268, 8700, 9143, 9597, 10062, 10538, 11025, 11523
Offset: 0

Author

Bruno Berselli, Jun 11 2013

Keywords

Comments

Sequences of numbers of the form n*(n*k - k + 6)/2:
. k from 0 to 10, respectively: A008585, A055998, A005563, A045943, A014105, A005475, A033428, A022264, A033991, A062741, A147874;
. k=11: a(n);
. k=12: A094159;
. k=13: 0, 3, 19, 48, 90, 145, 213, 294, 388, 495, 615, 748, 894, ...;
. k=14: 0, 3, 20, 51, 96, 155, 228, 315, 416, 531, 660, 803, 960, ...;
. k=15: A152773;
. k=16: A139272;
. k=17: 0, 3, 23, 60, 114, 185, 273, 378, 500, 639, 795, 968, ...;
. k=18: A152751;
. k=19: 0, 3, 25, 66, 126, 205, 303, 420, 556, 711, 885, 1078, ...;
. k=20: 0, 3, 26, 69, 132, 215, 318, 441, 584, 747, 930, 1133, ...;
. k=21: A152759;
. k=22: 0, 3, 28, 75, 144, 235, 348, 483, 640, 819, 1020, 1243, ...;
. k=23: 0, 3, 29, 78, 150, 245, 363, 504, 668, 855, 1065, 1298, ...;
. k=24: A152767;
. k=25: 0, 3, 31, 84, 162, 265, 393, 546, 724, 927, 1155, 1408, ...;
. k=26: 0, 3, 32, 87, 168, 275, 408, 567, 752, 963, 1200, 1463, ...;
. k=27: A153783;
. k=28: A195021;
. k=29: 0, 3, 35, 96, 186, 305, 453, 630, 836, 1071, 1335, 1628, ...;
. k=30: A153448;
. k=31: 0, 3, 37, 102, 198, 325, 483, 672, 892, 1143, 1425, 1738, ...;
. k=32: 0, 3, 38, 105, 204, 335, 498, 693, 920, 1179, 1470, 1793, ...;
. k=33: A153875.
Also:
a(n) - n = A180223(n);
a(n) + n = n*(11*n-3)/2 = 0, 4, 19, 45, 82, 130, 189, 259, ...;
a(n) - 2*n = A051865(n);
a(n) + 2*n = A022268(n);
a(n) - 3*n = A152740(n-1);
a(n) + 3*n = A022269(n);
a(n) - 4*n = n*(11*n-13)/2 = 0, -1, 9, 30, 62, 105, 159, 224, ...;
a(n) + 4*n = A254963(n);
a(n) - n*(n-1)/2 = A147874(n+1);
a(n) + n*(n-1)/2 = A094159(n) (case k=12);
a(n) - n*(n-1) = A062741(n) (see above, this is the case k=9);
a(n) + n*(n-1) = n*(13*n-7)/2 (case k=13);
a(n) - n*(n+1)/2 = A135706(n);
a(n) + n*(n+1)/2 = A033579(n);
a(n) - n*(n+1) = A051682(n);
a(n) + n*(n+1) = A186030(n);
a(n) - n^2 = A062708(n);
a(n) + n^2 = n*(13*n-5)/2 = 0, 4, 21, 51, 94, 150, 219, ..., etc.
Sum of reciprocals of a(n), for n > 0: 0.47118857003113149692081665034891...

Crossrefs

Cf. sequences in Comments lines.
First differences are in A017425.

Programs

  • Magma
    [n*(11*n-5)/2: n in [0..50]];
    
  • Magma
    I:=[0,3,17]; [n le 3 select I[n] else 3*Self(n-1)-3*Self(n-2)+Self(n-3): n in [1..46]]; // Vincenzo Librandi, Aug 18 2013
    
  • Mathematica
    Table[n (11 n - 5)/2, {n, 0, 50}]
    CoefficientList[Series[x (3 + 8 x) / (1 - x)^3, {x, 0, 45}], x] (* Vincenzo Librandi, Aug 18 2013 *)
    LinearRecurrence[{3,-3,1},{0,3,17},50] (* Harvey P. Dale, Jan 14 2019 *)
  • PARI
    a(n)=n*(11*n-5)/2 \\ Charles R Greathouse IV, Sep 24 2015

Formula

G.f.: x*(3+8*x)/(1-x)^3.
a(n) + a(-n) = A033584(n).
From Elmo R. Oliveira, Dec 27 2024: (Start)
E.g.f.: exp(x)*x*(6 + 11*x)/2.
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) for n > 2.
a(n) = n + A180223(n). (End)

A140673 a(n) = 3*n*(n + 5)/2.

Original entry on oeis.org

0, 9, 21, 36, 54, 75, 99, 126, 156, 189, 225, 264, 306, 351, 399, 450, 504, 561, 621, 684, 750, 819, 891, 966, 1044, 1125, 1209, 1296, 1386, 1479, 1575, 1674, 1776, 1881, 1989, 2100, 2214, 2331, 2451, 2574, 2700, 2829, 2961, 3096
Offset: 0

Author

Omar E. Pol, May 22 2008

Keywords

Comments

a(n) equals the number of vertices of the A256666(n)-th graph (see Illustration of initial terms in A256666 Links). - Ivan N. Ianakiev, Apr 20 2015

Crossrefs

Cf. A055998.
The generalized pentagonal numbers b*n+3*n*(n-1)/2, for b = 1 through 12, form sequences A000326, A005449, A045943, A115067, A140090, A140091, A059845, A140672, A140673, A140674, A140675, A151542.

Programs

  • Mathematica
    Table[Sum[i + n - 3, {i, 6, n}], {n, 5, 52}] (* Zerinvary Lajos, Jul 11 2009 *)
    Table[3 n (n + 5)/2, {n, 0, 50}] (* Bruno Berselli, Sep 05 2018 *)
    LinearRecurrence[{3,-3,1},{0,9,21},50] (* Harvey P. Dale, Jul 20 2023 *)
  • PARI
    concat(0, Vec(3*x*(3 - 2*x)/(1 - x)^3 + O(x^100))) \\ Michel Marcus, Apr 20 2015
    
  • PARI
    a(n) = 3*n*(n+5)/2; \\ Altug Alkan, Sep 05 2018

Formula

a(n) = A055998(n)*3 = (3*n^2 + 15*n)/2 = n*(3*n + 15)/2.
a(n) = 3*n + a(n-1) + 6 for n>0, a(0)=0. - Vincenzo Librandi, Aug 03 2010
G.f.: 3*x*(3 - 2*x)/(1 - x)^3. - Arkadiusz Wesolowski, Dec 24 2011
E.g.f.: (1/2)*(3*x^2 + 18*x)*exp(x). - G. C. Greubel, Jul 17 2017
From Amiram Eldar, Feb 25 2022: (Start)
Sum_{n>=1} 1/a(n) = 137/450.
Sum_{n>=1} (-1)^(n+1)/a(n) = 4*log(2)/15 - 47/450. (End)
Previous Showing 11-20 of 66 results. Next