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.

A084640 Generalized Jacobsthal numbers.

Original entry on oeis.org

0, 1, 5, 11, 25, 51, 105, 211, 425, 851, 1705, 3411, 6825, 13651, 27305, 54611, 109225, 218451, 436905, 873811, 1747625, 3495251, 6990505, 13981011, 27962025, 55924051, 111848105, 223696211, 447392425, 894784851, 1789569705, 3579139411
Offset: 0

Views

Author

Paul Barry, Jun 06 2003

Keywords

Comments

This is the sequence A(0,1;1,2;4) of the family of sequences [a,b:c,d:k] considered by G. Detlefs, and treated as A(a,b;c,d;k) in the W. Lang link given below. - Wolfdieter Lang, Oct 18 2010

Crossrefs

Programs

  • Haskell
    a084640 n = a084640_list !! n
    a084640_list = 0 : 1 : (map (+ 4) $
       zipWith (+) (map (* 2) a084640_list) (tail a084640_list))
    -- Reinhard Zumkeller, May 23 2013
    
  • Magma
    [5*2^n/3+(-1)^n/3-2: n in [0..35]]; // Vincenzo Librandi, Jun 15 2011
    
  • Mathematica
    LinearRecurrence[{2,1,-2},{0,1,5},40] (* Harvey P. Dale, Oct 27 2015 *)
  • PARI
    x='x+O('x^50); Vec(x*(1+3*x)/((1-x^2)*(1-2*x))) \\ G. C. Greubel, Sep 26 2017

Formula

G.f.: x*(1+3*x)/((1-x^2)*(1-2*x)).
a(n) = a(n-1) + 2a(n-2) + 4, a(0)=0, a(1)=1.
a(n) = (5*2^n + (-1)^n - 6)/3.
a(n) = A001045(n+2) + 4*A000975(n-3).
a(n+1) - 2*a(n) = period 2: repeat 1, 3. - Paul Curtz, Apr 03 2008
Contribution from Paul Curtz, Dec 10 2009: (Start)
a(n+2) - a(n) = A020714(n).
Le the array D(n,k) of the first differences be defined via D(0,k) = a(k); D(n+1,k) = D(n,k+1)-D(n,k).
Then D(n,n) = 4*A131577(n); D(1,k) = A084214(k+1); D(2,k) = A115102(k-1) for k>0; D(3,k) = (-1)^(k+1)*A083581(k). (End)
a(n) = 2*a(n-1) + a(n-2) - 2*a(n-3), a(0)=0, a(1)=1, a(2)=5. Observed by G. Detlefs. See the W. Lang link. - Wolfdieter Lang, Oct 18 2010

A307688 a(n) = 2*a(n-1)-2*a(n-2)+a(n-3)+2*a(n-4) with a(0)=a(1)=0, a(2)=2, a(3)=3.

Original entry on oeis.org

0, 0, 2, 3, 2, 0, 3, 14, 26, 27, 22, 44, 123, 234, 310, 363, 586, 1224, 2259, 3382, 4642, 7227, 13070, 23092, 36555, 54450, 85022, 143883, 245282, 396720, 616803, 973214, 1600106, 2664027, 4334662, 6887804, 10970523, 17828154, 29272390, 47634603, 76493626
Offset: 0

Views

Author

Keywords

Comments

This is an autosequence of the second kind, the companion to A192395.
The array D(n, k) of successive differences begins:
0, 0, 2, 3, 2, 0, 3, 14, 26, 27, ...
0, 2, 1, -1, -2, 3, 11, 12, 1, -5, ...
2, -1, -2, -1, 5, 8, 1, -11, -6, 27, ...
-3, -1, 1, 6, 3, -7, -12, 5, 33, 30, ...
2, 2, 5, -3, -10, -5, 17, 28, -3, -55, ...
0, 3, -8, -7, 5, 22, 11, -31, -52, 13, ...
...
The main diagonal (0,2,-2,6,-10,22,...) is essentially the same as A151575.
It can be seen that abs(D(n, 1)) = D(1, n).
The diagonal starting from the third 0 is -(-1)^n*11*A001045(n), inverse binomial transform of 11*A001045(n).

Crossrefs

Cf. A001045 (first and fifth upper diagonals), A014551 (second upper diagonal), A115102 (third), A155980 (fourth).

Programs

  • Mathematica
    a[0] = a[1] = 0; a[2] = 2; a[3] = 3; a[n_] := a[n] = 2*a[n-1] - 2*a[n-2] + a[n-3] + 2*a[n-4]; Table[a[n], {n, 0, 40}]
    LinearRecurrence[{2,-2,1,2},{0,0,2,3},50] (* Harvey P. Dale, Oct 01 2021 *)
  • PARI
    concat([0,0], Vec(x^2*(2 - x) / ((1 - x - x^2)*(1 - x + 2*x^2)) + O(x^40))) \\ Colin Barker, Apr 22 2019

Formula

G.f.: x^2*(2 - x) / ((1 - x - x^2)*(1 - x + 2*x^2)). - Colin Barker, Apr 22 2019
Showing 1-2 of 2 results.