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

A084775 a(n) = sum of absolute valued coefficients of (1+x-4*x^2)^n.

Original entry on oeis.org

1, 6, 34, 184, 956, 4776, 22986, 118304, 624634, 3281346, 17687330, 92606914, 470392898, 2348031430, 11932314170, 62345998488, 326780375778, 1691296908076, 8780141027670, 45168987187058, 230213109996786
Offset: 0

Views

Author

Paul D. Hanna, Jun 14 2003

Keywords

Crossrefs

Programs

  • Magma
    R:=PowerSeriesRing(Integers(), 100);
    f:= func< n,k | Coefficient(R!( (1+x-4*x^2)^n ), k) >;
    [(&+[ Abs(f(n,k)): k in [0..2*n]]): n in [0..40]]; // G. C. Greubel, Jun 03 2023
    
  • Mathematica
    T[n_, k_]:=T[n,k]=SeriesCoefficient[Series[(1+x-2*x^2)^n,{x,0,2n}], k];
    a[n_]:= a[n]= Sum[Abs[T[[k+1]]], {k,0,2n}];
    Table[a[n], {n,0,40}] (* G. C. Greubel, Jun 03 2023 *)
  • PARI
    for(n=0,40,S=sum(k=0,2*n,abs(polcoeff((1+1*x-4*x^2)^n,k,x))); print1(S","))
    
  • SageMath
    def f(n,k):
        P. = PowerSeriesRing(QQ)
        return P( (1+x-4*x^2)^n ).list()[k]
    def a(n): return sum( abs(f(n,k)) for k in range(2*n+1) )
    [a(n) for n in range(41)] # G. C. Greubel, Jun 03 2023

Formula

a(n) = Sum_{k=0..2*n} abs(f(n, k)), where f(n, k) = ((sqrt(17) -1)/2)^k * Sum_{j=0..k} binomial(n, j)*binomial(n, k-j)*(-1)^j*((1+sqrt(17))/4 )^(2*j). - G. C. Greubel, Jun 03 2023

A084776 a(n) = sum of absolute-valued coefficients of (1+2*x-x^2)^n.

Original entry on oeis.org

1, 4, 12, 36, 100, 300, 776, 2412, 6304, 19036, 50952, 148896, 393452, 1211444, 3167004, 9672772, 25295248, 76084796, 200590424, 608621376, 1617201648, 4908511140, 12658776540, 38907904188, 102775961200, 310485090044
Offset: 0

Views

Author

Paul D. Hanna, Jun 14 2003

Keywords

Crossrefs

Programs

  • Magma
    m:=40;
    R:=PowerSeriesRing(Integers(), 2*(m+2));
    f:= func< n,k | Coefficient(R!( (1+2*x-x^2)^n ), k) >;
    [(&+[ Abs(f(n,k)): k in [0..2*n]]): n in [0..m]]; // G. C. Greubel, Jun 03 2023
    
  • Mathematica
    T[n_, k_]:=T[n,k]=SeriesCoefficient[Series[(1+2*x-x^2)^n,{x,0,2n}], k];
    a[n_]:= a[n]= Sum[Abs[T[n,k]], {k,0,2n}];
    Table[a[n], {n,0,40}] (* G. C. Greubel, Jun 03 2023 *)
  • PARI
    for(n=0,40,S=sum(k=0,2*n,abs(polcoeff((1+2*x-x^2)^n,k,x))); print1(S","))
    
  • SageMath
    def f(n,k):
        P. = PowerSeriesRing(QQ)
        return P( (1+2*x-x^2)^n ).list()[k]
    def a(n): return sum( abs(f(n,k)) for k in range(2*n+1) )
    [a(n) for n in range(41)] # G. C. Greubel, Jun 03 2023

Formula

a(n) = Sum_{k=0..2*n} abs(f(n, k)), where f(n, k) = (sqrt(2) - 1)^k * Sum_{j=0..k} binomial(n, j)*binomial(n, k-j)*(-1)^j*(1+sqrt(2))^(2*j). - G. C. Greubel, Jun 03 2023

A084777 a(n) = sum of absolute-valued coefficients of (1+2*x-2*x^2)^n.

Original entry on oeis.org

1, 5, 17, 73, 273, 881, 3785, 13081, 48737, 184321, 632193, 2526305, 8854081, 32077921, 124093025, 428178641, 1638563969, 5878561921, 21469361537, 82252171393, 286863949025, 1061000856417, 3998983314849, 14361380710817
Offset: 0

Views

Author

Paul D. Hanna, Jun 14 2003

Keywords

Crossrefs

Programs

  • Magma
    m:=40;
    R:=PowerSeriesRing(Integers(), 2*(m+2));
    f:= func< n,k | Coefficient(R!( (1+2*x-2*x^2)^n ), k) >;
    [(&+[ Abs(f(n,k)): k in [0..2*n]]): n in [0..m]]; // G. C. Greubel, Jun 03 2023
    
  • Mathematica
    T[n_,k_]:=T[n,k]=SeriesCoefficient[Series[(1+2*x-2*x^2)^n,{x,0,2n}],k];
    a[n_]:= a[n]= Sum[Abs[T[n,k]], {k,0,2n}];
    Table[a[n], {n,0,40}] (* G. C. Greubel, Jun 03 2023 *)
  • PARI
    for(n=0,40,S=sum(k=0,2*n,abs(polcoeff((1+2*x-2*x^2)^n,k,x))); print1(S","))
    
  • SageMath
    def f(n,k):
        P. = PowerSeriesRing(QQ)
        return P( (1+2*x-2*x^2)^n ).list()[k]
    def a(n): return sum( abs(f(n,k)) for k in range(2*n+1) )
    [a(n) for n in range(41)] # G. C. Greubel, Jun 03 2023

Formula

a(n) = Sum_{k=0..2*n} abs(f(n, k)), where f(n, k) = ((sqrt(3) -1)/2)^k * Sum_{j=0..k} binomial(n, j)*binomial(n, k-j)*(-1)^j*((1+sqrt(3))/2 )^(2*j). - G. C. Greubel, Jun 03 2023

A084779 a(n) = sum of absolute-valued coefficients of (1+2*x-4*x^2)^n.

Original entry on oeis.org

1, 7, 41, 207, 1313, 7807, 42593, 232463, 1290433, 7604415, 42034721, 236031231, 1363681121, 7457831007, 39670144513, 231087069823, 1291433872385, 7373001299199, 41437235793921, 229538650588863, 1268719471103233
Offset: 0

Views

Author

Paul D. Hanna, Jun 14 2003

Keywords

Crossrefs

Programs

  • Magma
    m:=40;
    R:=PowerSeriesRing(Integers(), 2*(m+2));
    f:= func< n,k | Coefficient(R!( (1+2*x-4*x^2)^n ), k) >;
    [(&+[ Abs(f(n,k)): k in [0..2*n]]): n in [0..m]]; // G. C. Greubel, Jun 04 2023
    
  • Mathematica
    T[n_,k_]:=T[n,k]=SeriesCoefficient[Series[(1+2*x-4*x^2)^n,{x,0,2n}],k];
    a[n_]:= a[n]= Sum[Abs[T[n,k]], {k,0,2n}];
    Table[a[n], {n,0,40}] (* G. C. Greubel, Jun 04 2023 *)
  • PARI
    for(n=0,40,S=sum(k=0,2*n,abs(polcoeff((1+2*x-4*x^2)^n,k,x))); print1(S","))
    
  • SageMath
    def f(n,k):
        P. = PowerSeriesRing(QQ)
        return P( (1+2*x-4*x^2)^n ).list()[k]
    def a(n): return sum( abs(f(n,k)) for k in range(2*n+1) )
    [a(n) for n in range(41)] # G. C. Greubel, Jun 04 2023

Formula

a(n) = Sum_{k=0..2*n} abs(f(n, k)), where f(n, k) = (n!/(2*n-k)!)*i*(k-n)*2^k*5^(n/2)*LegendreP(n, n-k, 1/sqrt(5)). - G. C. Greubel, Jun 04 2023

A084780 a(n) = sum of absolute-valued coefficients of (1+3*x-x^2)^n.

Original entry on oeis.org

1, 5, 21, 77, 291, 1119, 3523, 15007, 50923, 182669, 701121, 2379129, 8909361, 32490021, 106309861, 423990203, 1456199483, 5089398187, 19942506259, 65753622619, 252337832801, 903751067081, 3026099773993, 11771846189609
Offset: 0

Views

Author

Paul D. Hanna, Jun 14 2003

Keywords

Comments

The expansion of (1 + a*x - b*x^2)^n is: (1 + a*x - b*x^2)^n = Sum_{k=0..2*n} f(n, k)*x^k, where f(n, k) = (n!/(2*n-k)!) * (-b)^((k-n)/2) * (a^2 + 4*b)^(n/2) * LegendreP(n, n-k, a/sqrt(a^2 + 4*b)). - G. C. Greubel, Jun 04 2023

Crossrefs

Programs

  • Magma
    m:=40;
    R:=PowerSeriesRing(Integers(), 2*(m+2));
    f:= func< n,k | Coefficient(R!( (1+3*x-x^2)^n ), k) >;
    [(&+[ Abs(f(n,k)): k in [0..2*n]]): n in [0..m]]; // G. C. Greubel, Jun 04 2023
    
  • Mathematica
    Table[Total[Abs[CoefficientList[Expand[(1+3x-x^2)^n],x]]],{n,0,30}] (* Harvey P. Dale, Jan 04 2012 *)
  • PARI
    for(n=0,40,S=sum(k=0,2*n,abs(polcoeff((1+3*x-x^2)^n,k,x))); print1(S","))
    
  • SageMath
    def f(n,k):
        P. = PowerSeriesRing(QQ)
        return P( (1+3*x-x^2)^n ).list()[k]
    def a(n): return sum( abs(f(n,k)) for k in range(2*n+1) )
    [a(n) for n in range(41)] # G. C. Greubel, Jun 04 2023

Formula

a(n) = Sum_{k=0..2*n} abs(f(n, k)), where f(n, k) = (n!/(2*n-k)!) * i^(k-n)*(13)^(n/2)*LegendreP(n, n-k, 3/sqrt(13)).. - G. C. Greubel, Jun 04 2023

A192205 a(n) = sum of absolute values of coefficients in (1-x-x^2+x^3)^n.

Original entry on oeis.org

1, 4, 12, 36, 116, 344, 1104, 3280, 10456, 31152, 98804, 295988, 935876, 2811540, 8870324, 26695724, 84060148, 253376840, 796635360, 2404558304, 7549431884, 22820942416, 71541295984, 216562743948, 677938097756, 2054922521644
Offset: 0

Views

Author

Paul D. Hanna, Jun 25 2011

Keywords

Comments

Conjecture: limit a(n)^(1/n) = 16*sqrt(3)/9 = 3.079201..., which is substantiated by the observation that the sums of the coefficients squared in (1-x-x^2+x^3)^n equals binomial(4n,n) (cf. A005810).

Examples

			The triangle A227964 of coefficients in (1+x-x^2-x^3)^n begins:
n=0: [1];
n=1: [1, -1, -1, 1];
n=2: [1, -2, -1, 4, -1, -2, 1];
n=3: [1, -3, 0, 8, -6, -6, 8, 0, -3, 1];
n=4: [1, -4, 2, 12, -17, -8, 28, -8, -17, 12, 2, -4, 1];
n=5: [1, -5, 5, 15, -35, -1, 65, -45, -45, 65, -1, -35, 15, 5, -5, 1];
n=6: [1, -6, 9, 16, -60, 24, 116, -144, -66, 220, -66, -144, 116, 24, -60, 16, 9, -6, 1]; ...
This sequence gives the sums of the absolute values of the coefficients for n>=0.
		

Crossrefs

Programs

  • Mathematica
    Table[Total[Abs[CoefficientList[Expand[(1-x-x^2+x^3)^n],x]]],{n,0,30}] (* Harvey P. Dale, Mar 03 2013 *)
  • PARI
    {a(n)=sum(k=0,3*n,abs(polcoeff((1-x-x^2+x^3)^n,k)))}
    for(n=0,30,print1(a(n),", "))

A192210 a(n) = sum of unsigned coefficients in (1+x+x^2-x^3)^n.

Original entry on oeis.org

1, 4, 10, 26, 80, 194, 504, 1442, 3710, 9536, 26842, 69014, 178704, 496602, 1316204, 3377206, 9242898, 24629944, 63304540, 172497622, 462822414, 1210912388, 3177522724, 8736822276, 22617998204, 59776061150, 163702751968, 433787373560
Offset: 0

Views

Author

Paul D. Hanna, Jun 25 2011

Keywords

Comments

What is the behavior of this sequence? Does there exist a g.f.?
It would be nice to know the (more accurate) values of the following limits:
(1) The position of the first negative coefficient in (1+x+x^2-x^3)^n, divided by n, seems to reach a limit near 0.398...
(2) Limit a(n)^(1/n) seems to exist near 2.6637...
(3) Limit a(n+1)/a(n) does not seem to be unique; attractors seem to exist near 2.66...

Examples

			Illustrate the coefficients in (1+x+x^2-x^3)^n by:
n=0: [1];
n=1: [1, 1, 1, -1];
n=2: [1, 2, 3, 0, -1, -2, 1];
n=3: [1, 3, 6, 4, 0, -6, -2, 0, 3, -1];
n=4: [1, 4, 10, 12, 7, -8, -12, -8, 7, 4, 2, -4, 1];
n=5: [1, 5, 15, 25, 25, 1, -25, -35, -5, 15, 21, -5, -5, -5, 5, -1];
n=6: [1, 6, 21, 44, 60, 36, -24, -84, -66, 0, 66, 36, -4, -36, 0, 4, 9, -6, 1];
n=7: [1, 7, 28, 70, 119, 119, 28, -132, -210, -126, 84, 168, 98, -70, -76, -28, 49, 7, 0, -14, 7, -1]; ...
This sequence gives the sums of the absolute values of the coefficients for n>=0.
		

Crossrefs

Programs

  • Mathematica
    Table[Total[Abs[CoefficientList[Expand[(1+x+x^2-x^3)^n],x]]],{n,0,30}] (* Harvey P. Dale, Oct 12 2012 *)
  • PARI
    {a(n)=sum(k=0,3*n,abs(polcoeff((1+x+x^2-x^3)^n,k)))}
Showing 1-7 of 7 results.