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

A299045 Rectangular array: A(n,k) = Sum_{j=0..k} (-1)^floor(j/2)*binomial(k-floor((j+1)/2), floor(j/2))*(-n)^(k-j), n >= 1, k >= 0, read by antidiagonals.

Original entry on oeis.org

1, 1, 0, 1, -1, -1, 1, -2, 1, 1, 1, -3, 5, -1, 0, 1, -4, 11, -13, 1, -1, 1, -5, 19, -41, 34, -1, 1, 1, -6, 29, -91, 153, -89, 1, 0, 1, -7, 41, -169, 436, -571, 233, -1, -1, 1, -8, 55, -281, 985, -2089, 2131, -610, 1, 1, 1, -9, 71, -433, 1926, -5741, 10009, -7953, 1597, -1, 0
Offset: 1

Views

Author

Keywords

Comments

This array is used to compute A269252: A269252(n) = least k such that |A(n,k)| is a prime, or -1 if no such k exists.
For detailed theory, see [Hone].
The array can be extended to k<0 with A(n, k) = -A(n, -k-1) for all k in Z. - Michael Somos, Jun 19 2023

Examples

			Array begins:
1   0  -1     1     0      -1       1         0        -1           1
1  -1   1    -1     1      -1       1        -1         1          -1
1  -2   5   -13    34     -89     233      -610      1597       -4181
1  -3  11   -41   153    -571    2131     -7953     29681     -110771
1  -4  19   -91   436   -2089   10009    -47956    229771    -1100899
1  -5  29  -169   985   -5741   33461   -195025   1136689    -6625109
1  -6  41  -281  1926  -13201   90481   -620166   4250681   -29134601
1  -7  55  -433  3409  -26839  211303  -1663585  13097377  -103115431
1  -8  71  -631  5608  -49841  442961  -3936808  34988311  -310957991
1  -9  89  -881  8721  -86329  854569  -8459361  83739041  -828931049
		

Crossrefs

Cf. A094954 (unsigned version of this array, but missing the first row).

Programs

  • Mathematica
    (* Array: *)
    Grid[Table[LinearRecurrence[{-n, -1}, {1, 1 - n}, 10], {n, 10}]]
    (*Array antidiagonals flattened (gives this sequence):*)
    A299045[n_, k_] := Sum[(-1)^(Floor[j/2]) Binomial[k - Floor[(j + 1)/2], Floor[j/2]] (-n)^(k - j), {j, 0, k}]; Flatten[Table[A299045[n - k, k], {n, 11}, {k, 0, n - 1}]]
  • PARI
    {A(n, k) = sum(j=0, k, (-1)^(j\2)*binomial(k-(j+1)\2, j\2)*(-n)^(k-j))}; /* Michael Somos, Jun 19 2023 */

Formula

G.f. for row n: (1 + x)/(1 + n*x + x^2), n >= 1.
A(n, k) = B(-n, k) where B = A294099. - Michael Somos, Jun 19 2023

A154811 a(n) = Fibonacci(2*n+1) mod 9.

Original entry on oeis.org

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

Views

Author

Paul Curtz, Jan 15 2009

Keywords

Comments

Periodic with period length 12.

Crossrefs

Programs

Formula

a(n) = A001519(n+1) mod 9 = A122367(n) mod 9 = |A099496(n)| mod 9.
From R. J. Mathar, Apr 10 2009: (Start)
a(n) = a(n-1) - a(n-6) + a(n-7).
G.f.: -(1 + x + 3*x^2 - x^3 + 3*x^4 + x^5 + x^6)/((x - 1)*(x^2 + 1)*(x^4 - x^2 + 1)). (End)

Extensions

Edited by R. J. Mathar, Jan 23 2009
Typo in A-number in first formula corrected by R. J. Mathar, Feb 23 2009

A155110 a(n) = 8*Fibonacci(2n+1).

Original entry on oeis.org

8, 16, 40, 104, 272, 712, 1864, 4880, 12776, 33448, 87568, 229256, 600200, 1571344, 4113832, 10770152, 28196624, 73819720, 193262536, 505967888, 1324641128, 3467955496, 9079225360, 23769720584, 62229936392, 162920088592, 426530329384, 1116670899560
Offset: 0

Views

Author

Paul Curtz, Jan 20 2009

Keywords

Crossrefs

Programs

Formula

a(n) = 8*A001519(n+1) = 8*A122367(n) = 8 *|A099496(n)|.
a(n) == A154811(n+6) (mod 9).
a(n) == A156551(n) (mod 10).
a(n) = A153873(n) - A027941(n).
G.f.: 8*(1 - x)/(1 - 3*x + x^2). - G. C. Greubel, Apr 21 2021

Extensions

Comments converted to formulas by R. J. Mathar, Oct 06 2009

A207605 Triangle of coefficients of polynomials u(n,x) jointly generated with A106195; see the Formula section.

Original entry on oeis.org

1, 2, 4, 1, 8, 4, 1, 16, 12, 5, 1, 32, 32, 18, 6, 1, 64, 80, 56, 25, 7, 1, 128, 192, 160, 88, 33, 8, 1, 256, 448, 432, 280, 129, 42, 9, 1, 512, 1024, 1120, 832, 450, 180, 52, 10, 1, 1024, 2304, 2816, 2352, 1452, 681, 242, 63, 11, 1, 2048, 5120, 6912, 6400, 4424, 2364, 985, 316, 75, 12, 1
Offset: 1

Views

Author

Clark Kimberling, Feb 19 2012

Keywords

Comments

Row sums: 1,2,5,13,... (odd-indexed Fibonacci numbers).
Alternating row sums: 1,2,3,5,... (Fibonacci numbers).
Subtriangle of the triangle given by (1, 1, 0, 0, 0, 0, 0, 0, 0, ...) DELTA (0, 0, 1, 0, 0, 0, 0, 0, 0, 0, ...) where DELTA is the operator defined in A084938. - Philippe Deléham, Mar 22 2012

Examples

			First five rows:
   1
   2
   4   1
   8   4   1
  16  12   5   1
  32  32  18   6   1
First four polynomials u(n,x): 1, 2, 4 + x, 8 + 4x + x^2.
(1, 1, 0, 0, 0, ...) DELTA (0, 0, 1, 0, 0, ...) begins:
   1
   1,  0
   2,  0,  0
   4,  1,  0,  0
   8,  4,  1,  0,  0
  16, 12,  5,  1,  0,  0
  32, 32, 18,  6,  1,  0,  0. - _Philippe Deléham_, Mar 22 2012
		

Crossrefs

Programs

  • Maple
    CoeffList := p -> op(PolynomialTools:-CoefficientList(p,x)):
    T := (n,k) -> binomial(n, k)*hypergeom([-k,n-k], [-n], x):
    P := [seq(add(simplify(T(n,k)),k=0..n), n=0..11)]:
    seq(CoeffList(p), p in P); # Peter Luschny, Feb 16 2018
  • Mathematica
    (* First program *)
    u[1, x_] := 1; v[1, x_] := 1; z = 16;
    u[n_, x_] := u[n - 1, x] + v[n - 1, x]
    v[n_, x_] := u[n - 1, x] + (x + 1) v[n - 1, x]
    Table[Factor[u[n, x]], {n, 1, z}]
    Table[Factor[v[n, x]], {n, 1, z}]
    cu = Table[CoefficientList[u[n, x], x], {n, 1, z}];
    TableForm[cu]
    Flatten[%]  (* A207605 *)
    Table[Expand[v[n, x]], {n, 1, z}]
    cv = Table[CoefficientList[v[n, x], x], {n, 1, z}];
    TableForm[cv]
    Flatten[%]  (* A106195 *)
    (* Second program *)
    T[n_, k_]:= T[n, k]= If[k<0 || k>n, 0, If[k==0, 2^(n+1), If[k==n, 1, 2*T[n-1, k] + T[n-1, k-1] - T[n-2, k-1] ]]]; Join[{1}, Table[T[n, k], {n,0,10}, {k,0,n}]]//Flatten (* G. C. Greubel, Mar 15 2020 *)
  • Python
    from sympy import Poly
    from sympy.abc import x
    def u(n, x): return 1 if n==1 else u(n - 1, x) + v(n - 1, x)
    def v(n, x): return 1 if n==1 else u(n - 1, x) + (x + 1)*v(n - 1, x)
    def a(n): return Poly(u(n, x), x).all_coeffs()[::-1]
    for n in range(1, 13): print(a(n)) # Indranil Ghosh, May 27 2017
    
  • Sage
    @CachedFunction
    def T(n, k):
        if (k<0 or k>n): return 0
        elif k == 0: return 2^(n+1)
        elif k == n: return 1
        else: return 2*T(n-1,k) + T(n-1,k-1) - T(n-2,k-1)
    [1]+[[T(n, k) for k in (0..n)] for n in (0..10)] # G. C. Greubel, Mar 15 2020

Formula

u(n,x) = u(n-1,x) + v(n-1,x), v(n,x) = u(n-1,x) + (x+1)v(n-1,x), where u(1,x)=1, v(1,x)=1.
T(n,k) = 2*T(n-1,k) + T(n-1,k-1) - T(n-2,k-1), T(1,0) = 1, T(2,0) = 2, T(2,1) = 0. - Philippe Deléham, Mar 22 2012
G.f.: x*y*(1-x*y)/(1-x*y-2*x+x^2*y). - R. J. Mathar, Aug 11 2015
T(n,k) = [x^k] Sum_{k=0..n} binomial(n, k)*hypergeom([-k, n-k], [-n], x). - Peter Luschny, Feb 16 2018
Sum_{k=1..n} T(n,k) = Fibonacci(2*n-1), n >= 1, = (-1)^(n-1)*A099496(n-1). - G. C. Greubel, Mar 15 2020

A156561 Floor(Fibonacci(2n+1)/9).

Original entry on oeis.org

0, 0, 0, 1, 3, 9, 25, 67, 177, 464, 1216, 3184, 8336, 21824, 57136, 149585, 391619, 1025273, 2684201, 7027331, 18397793, 48166048, 126100352, 330135008, 864304672, 2262779008, 5924032352, 15509318049, 40603921795, 106302447337, 278303420217
Offset: 0

Views

Author

Paul Curtz, Feb 10 2009

Keywords

Crossrefs

Cf. A069403.

Programs

  • Mathematica
    Floor[Fibonacci[2*Range[0,30]+1]/9] (* or *) LinearRecurrence[{4,-4,1,0,0,-1,4,-4,1},{0,0,0,1,3,9,25,67,177},31] (* Harvey P. Dale, Jun 06 2016 *)

Formula

a(n) = ( A000045(2n+1)-A154811(n) )/9 = floor(A122367(n)/9) = floor(A001519(n+1)/9) = floor( |A099496(n)|/9).
a(n)=3a(n-1)-a(n-2)+|A112690(n+10)|, i.e., a(n)-3a(n-1)+a(n-2) is a sequence of period 12 containing 0's and 1's. - R. J. Mathar, Feb 23 2009
G.f.: (1-x+x^2)/((1-x)(1+x^2)(1-3x+x^2)(1-x^2+x^4)). - R. J. Mathar, Feb 23 2009

Extensions

Edited and extended by R. J. Mathar, Jan 23 2009, Feb 23 2009
Showing 1-5 of 5 results.