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

A001350 Associated Mersenne numbers.

Original entry on oeis.org

0, 1, 1, 4, 5, 11, 16, 29, 45, 76, 121, 199, 320, 521, 841, 1364, 2205, 3571, 5776, 9349, 15125, 24476, 39601, 64079, 103680, 167761, 271441, 439204, 710645, 1149851, 1860496, 3010349, 4870845, 7881196, 12752041, 20633239, 33385280, 54018521, 87403801, 141422324
Offset: 0

Views

Author

Keywords

Comments

a(n) is last term in the period of the continued fraction expansion of phi^n (phi being the golden number). E.g.: n=10, phi^10=[122,1,121,1,121,1,121,...] (and the period may only have 1 or 2 terms). Also, a(n) = floor(phi^n)-((n+1) mod 2), or a(n) = A014217(n)-((n+1) mod 2). - Thomas Baruchel, Nov 05 2002 [continued fraction value corrected by Jon E. Schoenfield, Jan 20 2019]
a(n) is the resultant of the polynomials x^2-x-1 and x^(n+1)-x^n-1 for n >= 1. - Richard Choulet, Aug 05 2007
This is a divisibility sequence; that is, if n divides m, then a(n) divides a(m). - Michael Somos, Feb 12 2012
Gives the number of arrangements of black and white beads on a necklace with a total of n beads satisfying (1) there is at least one black bead (2) between any two black beads the number of white beads is even and (3) rotations and flippings of a necklace are considered distinct (see Butler). - Peter Bala, Mar 06 2014
This is the case P1 = 1, P2 = 0, Q = -1 of the 3-parameter family of 4th-order linear divisibility sequences found by Williams and Guy. - Peter Bala, Mar 31 2014
The resultant of the (s_2, s_2+n) pair, where s_n(X) is X^n-X-1, is -a(n). See Rush link. - Michel Marcus, Sep 30 2019

Examples

			G.f. = x + x^2 + 4*x^3 + 5*x^4 + 11*x^5 + 16*x^6 + 29*x^7 + 45*x^8 + 76*x^9 + ...
n=1: a(9)/a(3) = 76/4 = 19; a(18)/a(6) = 5776/16 = 361 = 19^2. - _Bob Selcoe_, Jun 01 2014
		

References

  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Magma
    [Floor(-(1 - ((1 + Sqrt(5))/2)^n - (-(1 + Sqrt(5))/2)^(-n) + (-1)^n)): n in [0..40]]; // Vincenzo Librandi, Aug 15 2011
    
  • Maple
    A001350 := n -> add(binomial(k-1, 2*k-n)*n/(n-k), k=0..n-1);
    seq(A001350(n), n=0..39); # Peter Luschny, Sep 26 2014
  • Mathematica
    Clear[f, n]; f[n_] = -(1 - ((1 + Sqrt[5])/2)^n - (-(1 + Sqrt[5])/2)^(-n) + (-1)^n); Table[FullSimplify[ExpandAll[f[n]]], {n, 0, 30}] (* Roger L. Bagula and Gary W. Adamson, Nov 26 2008 *)
    a[ n_] := LucasL[n] - 1 - (-1)^n; (* Michael Somos, May 18 2015 *)
    a[ n_] := SeriesCoefficient[ x D[ Log[ 1 + x / (1 - x - x^2)], x], {x, 0, n}]; (* Michael Somos, May 18 2015 *)
    LinearRecurrence[{1, 2, -1, -1}, {0, 1, 1, 4}, 40] (* Jean-François Alcover, Jan 07 2019 *)
  • PARI
    {a(n) = fibonacci(n+1) + fibonacci(n-1) - 1 - (-1)^n};
    
  • PARI
    {a(n) = my(w = quadgen(5)); simplify( -(w^n - 1) * ((-1/w)^n - 1))}; /* Michael Somos, Feb 12 2012 */
    
  • Python
    from sympy import lucas
    def A001350(n): return lucas(n)-((n&1^1)<<1) # Chai Wah Wu, Sep 23 2023

Formula

G.f.: x*(1+x^2)/((1-x^2)*(1-x-x^2)). - Simon Plouffe in his 1992 dissertation
a(n) = a(n-1) + a(n-2) + 1 -(-1)^n. a(-n) = (-1)^n * a(n).
a(n) = A050140(Fibonacci(n)). - Thomas Baruchel, Nov 05 2002
Convolution of F(n) and {1, 0, 2, 0, 2, ...}. a(n) = Sum_{k=0..n} ((1+(-1)^k)-0^k)*F(n-k) = Sum_{k=0..n} F(k)*((1+(-1)^(n-k))-0^(n-k)). - Paul Barry, Jul 19 2004
a(n) = 2*A074331(n) - A000045(n). - Paul Barry, Jul 19 2004
a(n) = Lucas_number(n) - 1 - (-1)^n = A000032(n) - 1 - (-1)^n. - Hieronymus Fischer, Feb 18 2006
a(n) = -(1 - ((1 + sqrt(5))/2)^n - (-(1 + sqrt(5))/2)^(-n) + (-1)^n). - Roger L. Bagula and Gary W. Adamson, Nov 26 2008
a(n) = n * Sum_{k=1..n} (Sum_{i=ceiling((n-k)/2)..(n-k)} (binomial(i,n-k-i)*binomial(k+i-1,k-1))/k*(-1)^(k+1)), n>0. - Vladimir Kruchinin, Sep 03 2010
a(n) = a(n-1) + 2*a(n-2) - a(n-3) - a(n-4). - Colin Barker, Apr 11 2014
a(n) = sqrt(A152152(n)). - Colin Barker, Apr 11 2014
a(n) = a(2*n)/A000032(n) when n is odd; a(n) = a(2*n)/(A000032(n+2)) when n is even. - Bob Selcoe, Jun 01 2014
a(12n+6)/a(4n+2) = (a(6n+3)/a(2n+1))^2. - Bob Selcoe, Jun 01 2014
a(n) = Sum_{k=0..n-1} binomial(k-1, 2*k-n)*n/(n-k). - Peter Luschny, Sep 26 2014
From Peter Bala, Mar 19 2015: (Start)
a(n) = -(alpha^n - 1)*(beta^n - 1), where alpha = 1/2*(1 + sqrt(5)) and beta = (1/2)*(1 - sqrt(5)).
a(n) = -det(I - M^n) where I is the 2 X 2 identity matrix and M = [ 1, 1; 1, 0 ]. Cf. A129744.
exp( Sum_{n >= 1} a(n)*x^n/n ) = 1 + Sum_{n >= 1} Fibonacci(n)*x^n. Cf. A004146. (End)
a(n) = A052952(n-1) + A052952(n-3). - R. J. Mathar, Jul 02 2018
a(n) = (L(2*n+1) - L(n+1)) mod (L(n+1)-1) for n > 0 where L(k)=A000032(k). - Art Baker, Jan 17 2019
a(n) = Sum_{j=n..2*n-1} L(j) mod Sum_{j=0..n-1} L(j) where L(j)=A000032(j). - Art Baker, Jan 20 2019
Convolution of (1, 0, 3, 0, 5, 0, 7, ...) and (1, 1, 1, 2, 3, 5, 8, 13, ...). - Gary W. Adamson, Jul 08 2019
a(n) = Sum_{d|n} d*A060280(d) = Sum_{d|n} A031367(d). [Baake, Roberts, Weiss, eq(2)]. - R. J. Mathar, Oct 19 2021

Extensions

Additional comments from Michael Somos, Aug 01 2002

A113224 a(2n) = A002315(n), a(2n+1) = A082639(n+1).

Original entry on oeis.org

1, 2, 7, 16, 41, 98, 239, 576, 1393, 3362, 8119, 19600, 47321, 114242, 275807, 665856, 1607521, 3880898, 9369319, 22619536, 54608393, 131836322, 318281039, 768398400, 1855077841, 4478554082, 10812186007, 26102926096, 63018038201
Offset: 0

Views

Author

Creighton Dement, Oct 18 2005

Keywords

Comments

From Paul D. Hanna, Oct 22 2005: (Start)
The logarithmic derivative of this sequence is twice the g.f. of A113282, where a(2*n) = A113282(2*n), a(4*n+1) = A113282(4*n+1) - 3, a(4*n+3) = A113282(4*n+3) - 1.
Equals the self-convolution of integer sequence A113281. (End)
With an offset of 1, this sequence is the case P1 = 2, P2 = 0, Q = -1 of the 3-parameter family of 4th-order linear divisibility sequences found by Williams and Guy. - Peter Bala, Mar 19 2015
Floretion Algebra Multiplication Program, FAMP Code: -2ibaseiseq[B*C], B = - .5'i + .5'j - .5i' + .5j' - 'kk' - .5'ik' - .5'jk' - .5'ki' - .5'kj'; C = + .5'i + .5i' + .5'ii' + .5e

Crossrefs

Programs

  • Magma
    [Floor((1+Sqrt(2))^(n+1)/2): n in [0..30]]; // Vincenzo Librandi, Mar 20 2015
  • Mathematica
    a[n_] := n*Sum[ Sum[ Binomial[i, n-k-i]*Binomial[k+i-1, k-1], {i, Ceiling[(n-k)/2], n-k}]*(1-(-1)^k)/(2*k), {k, 1, n}]; Table[a[n], {n, 1, 29}] (* Jean-François Alcover, Feb 26 2013, after Vladimir Kruchinin *)
    CoefficientList[Series[(1 + x^2) / ((x^2 - 1) (x^2 + 2 x - 1)), {x, 0, 30}], x] (* Vincenzo Librandi, Mar 20 2015 *)
    LinearRecurrence[{2,2,-2,-1},{1,2,7,16},30] (* Harvey P. Dale, Oct 10 2017 *)
  • Maxima
    a(n):=n*sum(sum(binomial(i,n-k-i)*binomial(k+i-1,k-1),i,ceiling((n-k)/2),n-k)*(1-(-1)^k)/(2*k),k,1,n); /* Vladimir Kruchinin, Apr 11 2011 */
    
  • PARI
    {a(n)=local(x=X+X*O(X^n));polcoeff((1+x^2)/(1-x^2)/(1-2*x-x^2),n,X)} \\ Paul D. Hanna
    

Formula

G.f.: (1+x^2)/((x-1)*(x+1)*(x^2+2*x-1)).
a(n+2) - a(n+1) - a(n) = A100828(n+1).
a(n) = -(u^(n+1)-1)*(v^(n+1)-1)/2 with u = 1+sqrt(2), v = 1-sqrt(2). - Vladeta Jovovic, May 30 2007
a(n) = n * Sum_{k=1..n} Sum_{i=ceiling((n-k)/2)..n-k} binomial(i,n-k-i)*binomial(k+i-1,k-1)*(1-(-1)^k)/(2*k). - Vladimir Kruchinin, Apr 11 2011
a(n) = A001333(n+1) - A000035(n). - R. J. Mathar, Apr 12 2011
a(n) = floor((1+sqrt(2))^(n+1)/2). - Bruno Berselli, Feb 06 2013
From Peter Bala, Mar 19 2015: (Start)
a(n) = (1/2) * A129744(n+1).
exp( Sum_{n >= 1} 2*a(n-1)*x^n/n ) = 1 + 2*Sum_{n >= 1} Pell(n) *x^n. (End)
a(n) = A105635(n-1) + A105635(n+1). - R. J. Mathar, Mar 23 2023

A305650 a(n) = -1/3 * (u^n-1)*(v^n-1) with u = 1+sqrt(3), v = 1-sqrt(3).

Original entry on oeis.org

1, 1, 9, 13, 61, 117, 421, 949, 2997, 7381, 21781, 56277, 160213, 424789, 1186389, 3189589, 8817493, 23883093, 65663317, 178568533, 489512277, 1334064469, 3651347797, 9962435925, 27244344661, 74380006741, 203315811669, 555257419093, 1517414896981, 4144807761237
Offset: 1

Views

Author

Seiichi Manyama, Jun 07 2018

Keywords

Crossrefs

Cf. A129744.

Programs

  • Mathematica
    LinearRecurrence[{1,6,-2,-4},{1,1,9,13},30] (* Harvey P. Dale, Jun 02 2019 *)
  • PARI
    Vec(x*(1 + 2*x^2) / ((1 - x)*(1 + 2*x)*(1 - 2*x - 2*x^2)) + O(x^40)) \\ Colin Barker, Jun 07 2018

Formula

a(n) = a(n-1) + 6*a(n-2) - 2*a(n-3) - 4*a(n-4) for n > 4.
G.f.: x*(1 + 2*x^2) / ((1 - x)*(1 + 2*x)*(1 - 2*x - 2*x^2)). - Colin Barker, Jun 07 2018

A324919 a(n) is the number of I^n-symmetric chains that are not I^k-symmetric for any k dividing n.

Original entry on oeis.org

2, 2, 12, 28, 80, 180, 476, 1120, 2772, 6640, 16236, 38976
Offset: 1

Views

Author

Felix Fröhlich, Sep 04 2019

Keywords

Comments

a(1)-a(12) are the terms of sequence b_n given in row 2 of table I. in Hermisson, Richard, Baake, 1997.

Crossrefs

Cf. A129744 (sequence a_n in the paper).
Showing 1-4 of 4 results.