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.

A157005 A Somos-4 variant.

Original entry on oeis.org

1, 2, 8, 24, 112, 736, 3776, 40192, 391424, 4203008, 85312512, 1270368256, 32235102208, 1038278549504, 27640704385024, 1549962593927168, 73624753456480256, 4273828146025070592, 435765959975516766208
Offset: 0

Views

Author

Paul Barry, Feb 20 2009

Keywords

Comments

Hankel transform of A157004.

Crossrefs

Programs

  • GAP
    a:=[1,2,8,24];; for n in [5..20] do a[n]:=(a[n-1]*a[n-3] + a[n-2]^2)/a[n-4]; od; a; # G. C. Greubel, Feb 23 2019
  • Magma
    I:=[1,2,8,24]; [n le 4 select I[n] else (Self(n-1)*Self(n-3) + Self(n-2)^2)/Self(n-4): n in [1..20]]; // G. C. Greubel, Feb 23 2019
    
  • Mathematica
    RecurrenceTable[{a[0]==1,a[1]==2,a[2]==8,a[3]==24,a[n]==(a[n-1] a[n-3]+a[n-2]^2)/a[n-4]},a,{n,20}]  (* Harvey P. Dale, Apr 30 2011 *)
  • PARI
    m=20; v=concat([1,2,8,24], vector(m-4)); for(n=5, m, v[n] = (v[n-1]*v[n-3] +v[n-2]^2)/v[n-4]); v \\ G. C. Greubel, Feb 23 2019
    
  • Sage
    def a(n):
        if (n==0): return 1
        elif (n==1): return 2
        elif (n==2): return 8
        elif (n==3): return 24
        else: return (a(n-1)*a(n-3) + a(n-2)^2)/a(n-4)
    [a(n) for n in (0..20)] # G. C. Greubel, Feb 23 2019
    

Formula

a(n) = (a(n-1)*a(n-3) + a(n-2)^2)/a(n-4), with a(0)=1, a(1)=2, a(2)=8, a(3)=24.
a(n) = 2^n*A006720(n+2).

A162546 A Somos-4 variant: a(n) = (36*a(n-1)*a(n-3) - 68*a(n-2)^2)/a(n-4).

Original entry on oeis.org

1, 1, -16, -644, -40592, -4821056, 17059328, 2492895195136, 10659285907800064, 86296767700623425536, 1081586547380924161458176, -36649408809924048998874742784, -18144416387824430577315746611724288
Offset: 0

Views

Author

Paul Barry, Jul 05 2009

Keywords

Comments

Hankel transform of A162543, A162548.

Crossrefs

Programs

  • GAP
    a:=[1,1,-16,-644];; for n in [5..20] do a[n]:=(36*a[n-1]*a[n-3] - 68*a[n-2]^2)/a[n-4]; od; a; # G. C. Greubel, Feb 23 2019
  • Magma
    I:=[1,1,-16,-644]; [n le 4 select I[n] else (36*Self(n-1) *Self(n-3) - 68*Self(n-2)^2)/Self(n-4): n in [1..20]]; // G. C. Greubel, Feb 23 2019
    
  • Mathematica
    RecurrenceTable[{a[n]==(36*a[n-1]*a[n-3] - 68*a[n-2]^2)/a[n-4], a[0]==1, a[1]==1, a[2]==-16, a[3]==-644}, a, {n,20}] (* G. C. Greubel, Feb 23 2019 *)
  • PARI
    m=20; v=concat([1,1,-16,-644], vector(m-4)); for(n=5, m, v[n] = (36*v[n-1]*v[n-3] -68*v[n-2]^2)/v[n-4]); v \\ G. C. Greubel, Feb 23 2019
    
  • Sage
    def a(n):
        if (n==0): return 1
        elif (n==1): return 1
        elif (n==2): return -16
        elif (n==3): return -644
        else: return (36*a(n-1)*a(n-3) - 68*a(n-2)^2)/a(n-4)
    [a(n) for n in (1..20)] # G. C. Greubel, Feb 23 2019
    

A157101 A Somos-4 variant.

Original entry on oeis.org

1, -1, -5, -4, 29, 129, -65, -3689, -16264, 113689, 2382785, 7001471, -398035821, -7911171596, 43244638645, 6480598259201, 124106986093951, -5987117709349201, -541051130050800400, -4830209396684261199
Offset: 0

Views

Author

Paul Barry, Feb 22 2009

Keywords

Comments

Hankel transform of A157100.

Crossrefs

Programs

  • GAP
    a:=[1,-1,-5,-4];; for n in [5..20] do a[n]:=(a[n-1]*a[n-3] + a[n-2]^2)/a[n-4]; od; a; # G. C. Greubel, Feb 23 2019
  • Magma
    I:=[1,-1,-5,-4]; [n le 4 select I[n] else (Self(n-1)*Self(n-3) + Self(n-2)^2)/Self(n-4): n in [1..20]]; // G. C. Greubel, Feb 23 2019
    
  • Mathematica
    RecurrenceTable[{a[n]==(a[n-1]*a[n-3]+a[n-2]^2)/a[n-4], a[0]==1, a[1]==-1, a[2]==-5, a[3]==-4}, a, {n,20}] (* G. C. Greubel, Feb 23 2019 *)
  • PARI
    m=20; v=concat([1,-1,-5,-4], vector(m-4)); for(n=5, m, v[n] = (v[n-1]*v[n-3] +v[n-2]^2)/v[n-4]); v \\ G. C. Greubel, Feb 23 2019
    
  • Sage
    def a(n):
        if (n==0): return 1
        elif (n==1): return -1
        elif (n==2): return -5
        elif (n==3): return -4
        else: return (a(n-1)*a(n-3) + a(n-2)^2)/a(n-4)
    [a(n) for n in (0..20)] # G. C. Greubel, Feb 23 2019
    

Formula

a(n) = (a(n-1)*a(n-3) + a(n-2)^2)/a(n-4), with a(0)=1, a(1)=-1, a(2)=-5, a(3)=-4.
a(n) = A051138(n+1) for all n in Z. - Michael Somos, Jul 17 2016

A124431 a(n) = Sum_{k=0..n} 2^k*C([(n+k)/2],k)*C([(n+k+1)/2],k) where [x]=floor(x).

Original entry on oeis.org

1, 3, 9, 29, 97, 331, 1145, 4001, 14089, 49915, 177713, 635293, 2278841, 8198227, 29567729, 106872961, 387038993, 1404052659, 5101219929, 18559193245, 67605310097, 246541193883, 899999057385, 3288522934433, 12026324883865
Offset: 0

Views

Author

Paul D. Hanna, Oct 31 2006

Keywords

Comments

This is the inverse Motzkin transform of A026378 assuming offset 1 here. - R. J. Mathar, Jul 07 2009
Hankel transform is Somos-4 variant A162547. - Paul Barry, Jan 09 2011
a(n) is the number of peakless Motzkin paths of length n in which the (1,0)-steps at level 0 come in 3 colors and those at a higher level come in 2 colors. Example: a(3)=29 because, denoting U=(1,1), H=(1,0), and D=(1,-1), we have 3^3 = 27 paths of shape HHH and 2 paths of shape UHD. - Emeric Deutsch, May 03 2011
Conjecture: (n+1)*a(n) -2*(2*n+1)*a(n-1) +2*(n-1)*a(n-2) +2*(5-2*n)*a(n-3) +(n-3)*a(n-4) =0. - R. J. Mathar, Aug 09 2012

Examples

			G.f. = 1 + 3*x + 9*x^2 + 29*x^3 + 97*x^4 + 331*x^5 + 1145*x^6 + 4001*x^7 + ...
		

Crossrefs

Cf. A124428.

Programs

  • Magma
    R:=PowerSeriesRing(Rationals(), 30); Coefficients(R!( (Sqrt((1+x^2)/(1-4*x+x^2)) -1)/(2*x) )); // G. C. Greubel, Feb 26 2019
    
  • Mathematica
    Table[Sum[2^k Binomial[Floor[(n+k)/2],k]Binomial[Floor[(n+k+1)/2],k],{k,0,n}],{n,0,30}] (* Harvey P. Dale, May 20 2012 *)
    CoefficientList[Series[(Sqrt[(1+x^2)/(1-4*x+x^2)] -1)/(2*x), {x,0,30}],x] (* G. C. Greubel, Feb 26 2019 *)
  • PARI
    a(n)=sum(k=0,n,2^k*binomial((n+k)\2,k)*binomial((n+k+1)\2,k))
    
  • PARI
    my(x='x+O('x^30)); Vec((sqrt((1+x^2)/(1-4*x+x^2)) -1)/(2*x)) \\ G. C. Greubel, Feb 26 2019
    
  • Sage
    ((sqrt((1+x^2)/(1-4*x+x^2)) -1)/(2*x)).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, Feb 26 2019

Formula

a(n) = Sum_{k=0..n} 2^k*A124428(n+k,k).
G.f.: (((x^2+1)*(1-4*x+x^2))^(1/2) - (1-4*x+x^2))/(2*x*(1-4*x+x^2)). - Maksym Voznyy (voznyy(AT)mail.ru), Aug 12 2009
G.f.: (1/(1-4*x+x^2))*c(-x/(1-4*x+x^2)), c(x) the g.f. of A000108. - Paul Barry, Jan 09 2011
G.f.: G(0)/(2*x) - 1/(2*x), where G(k)= 1 + 4*x*(4*k+1)/( (1+x^2)*(4*k+2) - x*(1+x^2)*(4*k+2)*(4*k+3)/(x*(4*k+3) + (1+x^2)*(k+1)/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 26 2013
a(n) ~ sqrt(14*sqrt(3)-24) * (2+sqrt(3))^(n+2) / (2*sqrt(3*Pi*n)). - Vaclav Kotesovec, Feb 03 2014
0 = a(n)*(+a(n+1) - 6*a(n+2) + 6*a(n+3) - 18*a(n+4) + 5*a(n+5)) + a(n+1)*(-2*a(n+1) + 14*a(n+2) - 10*a(n+3) + 61*a(n+4) - 18*a(n+5)) + a(n+2)*(+4*a(n+2) - 28*a(n+3) - 10*a(n+4) + 6*a(n+5)) + a(n+3)*(+4*a(n+3) + 14*a(n+4) - 6*a(n+5)) + a(n+4)*(-2*a(n+4) + a(n+5)) if n>=0. - Michael Somos, Aug 06 2014
Conjecture: +(n+1)*a(n) +2*(-2*n-1)*a(n-1) +2*(n-1)*a(n-2) +2*(-2*n+5)*a(n-3) +(n-3)*a(n-4)=0. - R. J. Mathar, Jun 17 2016
Showing 1-4 of 4 results.