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

A000816 E.g.f.: Sum_{n >= 0} a(n) * x^(2*n) / (2*n)! = sin(x)^2 / cos(2*x).

Original entry on oeis.org

0, 2, 40, 1952, 177280, 25866752, 5535262720, 1633165156352, 635421069967360, 315212388819402752, 194181169538675507200, 145435130631317935357952, 130145345400688287667978240, 137139396592145493713802493952
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Union[ Range[0, 26]! CoefficientList[ Series[ Sin[x]^2/Cos[ 2x], {x, 0, 26}], x]] (* Robert G. Wilson v, Apr 16 2011 *)
    Table[(-1)^(n + 1) 2^(2 n) I PolyLog[-2 n, I], {n, 1, 13}] (* Artur Jasinski, Mar 21 2022 *)
    With[{nn=30},Take[CoefficientList[Series[Sin[x]^2/Cos[2x],{x,0,nn}],x] Range[0,nn]!,{1,-1,2}]] (* Harvey P. Dale, Oct 18 2024 *)
  • PARI
    {a(n) = local(m); if( n<0, 0, m = 2*n; m! * polcoeff( 1 / (2 - 1 / cos(x + x * O(x^m))^2) - 1, m))} /* Michael Somos, Apr 16 2011 */
    
  • Sage
    @CachedFunction
    def sp(n,x) :
        if n == 0 : return 1
        return -add(2^(n-k)*sp(k,1/2)*binomial(n,k) for k in range(n)[::2])
    def A000816(n) : return 0 if n == 0 else abs(sp(2*n,x)/2)
    [A000816(n) for n in (0..13)]   # Peter Luschny, Jul 30 2012

Formula

(1/2) * A002436(n), n > 0. - Ralf Stephan, Mar 09 2004
a(n) = 2^(2*n - 1) * A000364(n) except at n=0.
E.g.f.: sin(x)^2/cos(2x) = 1/Q(0) - 1/2; Q(k) = 1 + 1/(1-2*(x^2)/(2*(x^2)-(k+1)*(2k+1)/Q(k+1))); (continued fraction). - Sergei N. Gladkovskii, Nov 18 2011
a(n) = A000819(n) unless n=0.
G.f.: (1/(G(0))-1)/2 where G(k) = 1 - 4*x*(k+1)^2/G(k+1); (continued fraction). - Sergei N. Gladkovskii, Jan 12 2013
G.f.: T(0)/2 - 1/2, where T(k) = 1 - 4*x*(k+1)^2/( 4*x*(k+1)^2 - 1/T(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Oct 25 2013
E.g.f.: sin(x)^2/cos(2*x) = x^2/(1-2*x^2)*T(0), where T(k) = 1 - x^2*(2*k+1)*(2*k+2)/( x^2*(2*k+1)*(2*k+2) + ((k+1)*(2*k+1) - 2*x^2)*((k+2)*(2*k+3) - 2*x^2)/T(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Oct 25 2013
From Artur Jasinski, Mar 21 2022: (Start)
For n > 0:
a(n) = Pi^(2*n-1)*(-Psi(2*n,1/4) - (4^n)*(2^(2*n+1)-1)*Gamma(2*n+1)*Zeta(2*n+1)).
a(n) = (-1)^(n+1)*2^(2*n)*i*Li_(2*n,i) where i=sqrt(-1) and Li is polylogarithm function.
a(n) = (-64)^n*(zeta(-2*n,1/4)-zeta(-2*n,3/4)) where zeta is Hurwitz zeta function.
a(n) = (-16)^n*lerchphi(-1,-2*n,1/2). (End)

A354065 Product_{n>=1} 1 / (1 - x^n)^(a(n)/n!) = 1 + tan(x).

Original entry on oeis.org

1, -2, 2, -8, 56, -496, 3184, -22784, 273920, -4539136, 48104704, -506000384, 10591523840, -204528633856, 2888557717504, -53417657237504, 1249919350046720, -28453501844586496, 624022403933077504, -13729309300086800384, 372737701735949926400, -11010228423219933085696
Offset: 1

Views

Author

Ilya Gutkovskiy, May 16 2022

Keywords

Crossrefs

Programs

  • Mathematica
    nmax = 22; CoefficientList[Series[Sum[MoebiusMu[k] Log[1 + Tan[x^k]]/k, {k, 1, nmax}], {x, 0, nmax}], x] Range[0, nmax]! // Rest

Formula

E.g.f.: Sum_{k>=1} mu(k) * log(1 + tan(x^k)) / k.

A024299 a(n) = (2*n)! [x^(2*n)] log(1 + tanh(x)^2)/2.

Original entry on oeis.org

0, 1, -14, 496, -34544, 4055296, -724212224, 183218384896, -62380415842304, 27507260369207296, -15250924309151350784, 10384039093607251050496, -8517991922318587187953664, 8285309769460200661892202496, -9429010285390912531529354706944
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    L:=RiemannZeta();
    [0] cat [-Round(2^(2*n-1)*(4^n-2)*(4^n-1)*Evaluate(L, 1-2*n)): n in [1..15]]; // G. C. Greubel, Jul 12 2022
    
  • Maple
    a := n -> `if`(n=0, 0, -2^(2*n-1)*(4^n-2)*(4^n-1)*Zeta(1-2*n)):
    seq(a(n), n=0..14); # Peter Luschny, Oct 29 2020
  • Mathematica
    With[{nn=30},Take[CoefficientList[Series[Log[1+Tanh[x]^2]/2,{x,0,nn}],x] Range[0,nn]!,{1,-1,2}]] (* Harvey P. Dale, Dec 12 2021 *)
  • PARI
    my(x='x+O('x^30), v = concat([0,0], Vec(serlaplace (log(1+tanh(x)^2)/2)))); vector(#v\2, k, v[2*k-1]) \\ Michel Marcus, Oct 29 2020
    
  • SageMath
    [0]+[-2^(2*n-1)*(4^n-2)*(4^n-1)*zeta(1-2*n) for n in (1..15)] # G. C. Greubel, Jul 12 2022

Formula

a(n) = A009403(n)/2.
a(n) = -2^(2*n-1)*(4^n - 2)*(4^n - 1)*zeta(1-2*n) for n >= 1. - Peter Luschny, Oct 29 2020

Extensions

Extended with signs, Mar 1997
Previous Mathematica program replaced by Harvey P. Dale, Dec 12 2021

A093049 n-1 minus exponent of 2 in n, a(0) = 0.

Original entry on oeis.org

0, 0, 0, 2, 1, 4, 4, 6, 4, 8, 8, 10, 9, 12, 12, 14, 11, 16, 16, 18, 17, 20, 20, 22, 20, 24, 24, 26, 25, 28, 28, 30, 26, 32, 32, 34, 33, 36, 36, 38, 36, 40, 40, 42, 41, 44, 44, 46, 43, 48, 48, 50, 49, 52, 52, 54, 52, 56, 56, 58, 57, 60, 60, 62, 57, 64, 64, 66, 65, 68
Offset: 0

Views

Author

Ralf Stephan, Mar 16 2004

Keywords

Examples

			G.f. = 2*x^3 + x^4 + 4*x^5 + 4*x^6 + 6*x^7 + 4*x^8 + 8*x^9 + 8*x^10 + ... - _Michael Somos_, Jan 25 2020
		

Crossrefs

a(n) = n - A007814(n) - 1 = A093048(n) - 1, n>0.
a(n) is the exponent of 2 in A001761(n+1), A002105(n), A002682(n-1), A006963(n), A036770(n-1), A059837(n), A084623(n), |A003707(n)|, |A011859(n)|.

Programs

  • Mathematica
    a[ n_] := If[ n == 0, 0, n - 1 - IntegerExponent[n, 2]]; (* Michael Somos, Jan 25 2020 *)
  • PARI
    a(n)=if(n<1,0,if(n%2==0,a(n/2)+n/2-1,n-1))
    
  • PARI
    {a(n) = if( n, n - 1 - valuation(n, 2))}; /* Michael Somos, Jan 25 2020 */
    
  • Python
    def A093049(n): return n-1-(~n& n-1).bit_length() if n else 0 # Chai Wah Wu, Jul 07 2022

Formula

Recurrence: a(2n) = a(n) + n - 1, a(2n+1) = 2n.
G.f.: sum(k>=0, t^3(t+2)/(1-t^2)^2, t=x^2^k).

A274805 The logarithmic transform of sigma(n).

Original entry on oeis.org

1, 2, -3, -6, 45, 11, -1372, 4298, 59244, -573463, -2432023, 75984243, -136498141, -10881169822, 100704750342, 1514280063802, -36086469752977, -102642110690866, 11883894518252419, -77863424962770751, -3705485804176583500, 71306510264347489177
Offset: 1

Views

Author

Johannes W. Meijer, Jul 27 2016

Keywords

Comments

The logarithmic transform [LOG] transforms an input sequence b(n) into the output sequence a(n). The LOG transform is the inverse of the exponential transform [EXP], see the Weisstein link and the Sloane and Plouffe reference. This relation goes by the name of Riddell’s formula. For information about the EXP transform see A274804. The logarithmic transform is related to the inverse multinomial transform, see A274844 and the first formula.
The definition of the LOG transform, see the second formula, shows that n >= 1. To preserve the identity EXP[LOG[b(n)]] = b(n) for n >= 0 for a sequence b(n) with offset 0 the shifted sequence b(n-1) with offset 1 has to be used as input for the LOG transform, otherwise information about b(0) will be lost in transformation.
In the a(n) formulas, see the examples, the cumulant expansion numbers A127671 appear.
We observe that the logarithmic transform leaves the value of a(0) undefined.
The Maple programs can be used to generate the logarithmic transform of a sequence. The first program uses a formula found by Alois P. Heinz, see A001187 and the first formula. The second program uses the definition of the logarithmic transform, see the Weisstein link and the second formula. The third program uses information about the inverse of the logarithmic transform, see A274804.

Examples

			Some a(n) formulas, see A127671:
a(0) = undefined
a(1) = 1*x(1)
a(2) = 1*x(2) - x(1)^2
a(3) = 1*x(3) - 3*x(1)*x(2) + 2*x(1)^3
a(4) = 1*x(4) - 4*x(1)*x(3) - 3*x(2)^2 + 12*x(1)^2*x(2) - 6*x(1)^4
a(5) = 1*x(5) - 5*x(1)*x(4) - 10*x(2)*x(3) + 20*x(1)^2*x(3) + 30*x(1)*x(2)^2 - 60*x(1)^3*x(2) + 24*x(1)^5
		

References

  • Frank Harary and Edgar M. Palmer, Graphical Enumeration, 1973.
  • Robert James Riddell, Contributions to the theory of condensation, Dissertation, University of Michigan, Ann Arbor, 1951.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, 1995, pp. 18-23.

Crossrefs

Some LOG transform pairs are, n >= 1: A006125(n-1) and A033678(n); A006125(n) and A001187(n); A006125(n+1) and A062740(n); A000045(n) and A112005(n); A000045(n+1) and A007553(n); A000040(n) and A007447(n); A000051(n) and (-1)*A263968(n-1); A002416(n) and A062738(n); A000290(n) and A033464(n-1); A029725(n-1) and A116652(n-1); A052332(n) and A002031(n+1); A027641(n)/A027642(n) and (-1)*A060054(n+1)/(A075180(n-1).

Programs

  • Maple
    nmax:=22: with(numtheory): b := proc(n): sigma(n) end: a:= proc(n) option remember; b(n) - add(k*binomial(n, k)*b(n-k)*a(k), k=1..n-1)/n: end: seq(a(n), n=1..nmax); # End first LOG program.
    nmax:=22: with(numtheory): b := proc(n): sigma(n) end: t1 := log(1 + add(b(n)*x^n/n!, n=1..nmax+1)): t2 := series(t1, x, nmax+1): a := proc(n): n!*coeff(t2, x, n) end: seq(a(n), n=1..nmax); # End second LOG program.
    nmax:=22: with(numtheory): b := proc(n): sigma(n) end: f := series(exp(add(r(n)*x^n/n!, n=1..nmax+1)), x, nmax+1): d := proc(n): n!*coeff(f, x, n) end: a(1):=b(1): r(1):= b(1): for n from 2 to nmax+1 do r(n) := solve(d(n)-b(n), r(n)): a(n):=r(n): od: seq(a(n), n=1..nmax); # End third LOG program.
  • Mathematica
    a[1] = 1; a[n_] := a[n] = DivisorSigma[1, n] - Sum[k*Binomial[n, k] * DivisorSigma[1, n-k]*a[k], {k, 1, n-1}]/n; Table[a[n], {n, 1, 22}] (* Jean-François Alcover, Feb 27 2017 *)
  • PARI
    N=33; x='x+O('x^N); Vec(serlaplace(log(1+sum(n=1,N,sigma(n)*x^n/n!)))) \\ Joerg Arndt, Feb 27 2017

Formula

a(n) = b(n) - Sum_{k = 1..n-1}((k*binomial(n, k)*b(n-k)*a(k))/n), n >= 1, with b(n) = A000203(n) = sigma(n).
E.g.f. log(1+ Sum_{n >= 1}(b(n)*x^n/n!)), n >= 1, with b(n) = A000203(n) = sigma(n).

A331610 Expansion of e.g.f.: exp(1 / (1 - tan(x)) - 1).

Original entry on oeis.org

1, 1, 3, 15, 97, 777, 7379, 80983, 1007137, 13986289, 214383171, 3593224767, 65347120705, 1281151315641, 26928292883795, 603928982033863, 14392387319349697, 363135896514611041, 9669298448057196291, 270932711729869233903, 7967970654277850949025
Offset: 0

Views

Author

Ilya Gutkovskiy, Jan 22 2020

Keywords

Crossrefs

Programs

  • Maple
    S:= series(exp(1/(1-tan(x))-1), x, 31):
    seq(coeff(S,x,i)*i!, i=0..30); # Robert Israel, Dec 10 2024
  • Mathematica
    nmax = 20; CoefficientList[Series[Exp[1/(1 - Tan[x]) - 1], {x, 0, nmax}], x] Range[0, nmax]!
    A000111[n_] := If[EvenQ[n], Abs[EulerE[n]], Abs[(2^(n + 1) (2^(n + 1) - 1) BernoulliB[n + 1])/(n + 1)]]; a[0] = 1; a[n_] := a[n] = Sum[Binomial[n - 1, k - 1] 2^(k - 1) A000111[k] a[n - k], {k, 1, n}]; Table[a[n], {n, 0, 20}]

Formula

E.g.f.: exp(sin(x) / (cos(x) - sin(x))).
a(0) = 1; a(n) = Sum_{k=1..n} binomial(n-1,k-1) * 2^(k-1) * A000111(k) * a(n-k).
a(n) ~ 2^(2*n - 1/4) * exp(1/Pi - 1/2 + 2^(3/2)*sqrt(n/Pi) - n) * n^(n - 1/4) / Pi^(n + 1/4). - Vaclav Kotesovec, Jan 27 2020

A296837 Expansion of e.g.f. log(1 + x*tan(x/2)) (even powers only).

Original entry on oeis.org

0, 1, -2, 18, -312, 9470, -436860, 28616322, -2522596496, 288046961190, -41355026494020, 7291524732108650, -1548849359704927896, 390122366308850972238, -114968364853645904762252, 39189956630839558368115410, -15300235972710835734174638880
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 21 2017

Keywords

Examples

			log(1 + x*tan(x/2)) = x^2/2! - 2*x^4/4! + 18*x^6/6! - 312*x^8/8! + ...
		

Crossrefs

Programs

  • Mathematica
    nmax = 16; Table[(CoefficientList[Series[Log[1 + x Tan[x/2]], {x, 0, 2 nmax}], x] Range[0, 2 nmax]!)[[n]], {n, 1, 2 nmax + 1, 2}]

Formula

a(n) = (2*n)! * [x^(2*n)] log(1 + x*tan(x/2)).
a(n) ~ -(-1)^n * sqrt(Pi) * 2^(2*n + 1) * n^(2*n - 1/2) / (r^(2*n) * exp(2*n)), where r = 1.54340463841820844795870974005331555369788376471926269... is the root of the equation r*tanh(r/2) = 1. - Vaclav Kotesovec, Dec 21 2017

A296838 Expansion of e.g.f. log(1 + x*tanh(x/2)) (even powers only).

Original entry on oeis.org

0, 1, -4, 48, -1186, 50060, -3226206, 294835184, -36270477034, 5779302944436, -1157856177719830, 284876691727454552, -84442374415240892898, 29680054107768128647388, -12205478262363331593956686, 5805823539844285054558025280, -3163004294186696659107788567386
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 21 2017

Keywords

Examples

			log(1 + x*tanh(x/2)) = x^2/2! - 4*x^4/4! + 48*x^6/6! - 1186*x^8/8! + ...
		

Crossrefs

Programs

  • Mathematica
    nmax = 16; Table[(CoefficientList[Series[Log[1 + x Tanh[x/2]], {x, 0, 2 nmax}], x] Range[0, 2 nmax]!)[[n]], {n, 1, 2 nmax + 1, 2}]

Formula

a(n) = (2*n)! * [x^(2*n)] log(1 + x*tanh(x/2)).
a(n) ~ -(-1)^n * sqrt(Pi) * 2^(2*n + 1) * n^(2*n - 1/2) / (r^(2*n) * exp(2*n)), where r = 1.306542374188806202228727831923118284841279755635... is the root of the equation r * tan(r/2) = 1. - Vaclav Kotesovec, Dec 21 2017

A331978 E.g.f.: -log(2 - cosh(x)) (even powers only).

Original entry on oeis.org

0, 1, 4, 46, 1114, 46246, 2933074, 263817646, 31943268634, 5009616448246, 987840438629794, 239217148602642046, 69790939492563608554, 24143849395162438623046, 9772368696995766705116914, 4575221153658910691872135246, 2453303387149157947685779986874
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 03 2020

Keywords

Crossrefs

Programs

  • Maple
    ptan := proc(n) option remember;
        if irem(n, 2) = 0 then 0 else
        add(`if`(k=0, 1, binomial(n, k)*ptan(n - k)), k = 0..n-1, 2) fi end:
    A331978 := n -> ptan(2*n - 1):
    seq(A331978(n), n = 0..16);  # Peter Luschny, Jun 06 2022
  • Mathematica
    nmax = 16; Table[(CoefficientList[Series[-Log[2 - Cosh[x]], {x, 0, 2 nmax}], x] Range[0, 2 nmax]!)[[n]], {n, 1, 2 nmax + 1, 2}]

Formula

a(0) = 0; a(n) = A094088(n) - (1/n) * Sum_{k=1..n-1} binomial(2*n,2*k) * A094088(n-k) * k * a(k).
a(n) ~ (2*n)! / (n * log(2 + sqrt(3))^(2*n)). - Vaclav Kotesovec, Feb 07 2020

A107729 Triangle T(n,k), 0 <= k <= n, read by rows, defined by T(0,0) = 1; T(0,k) = 0 if k < 0 or if k > 0; T(n,k) = k*T(n-1,k-1) + (k+2)*T(n-1,k+1).

Original entry on oeis.org

1, 0, 1, 2, 0, 2, 0, 8, 0, 6, 16, 0, 40, 0, 24, 0, 136, 0, 240, 0, 120, 272, 0, 1232, 0, 1680, 0, 720, 0, 3968, 0, 12096, 0, 13440, 0, 5040, 7936, 0, 56320, 0, 129024, 0, 120960, 0, 40320, 0, 176896, 0, 814080, 0, 1491840, 0, 1209600, 0, 362880, 353792, 0
Offset: 0

Views

Author

N. J. A. Sloane, Jun 10 2005

Keywords

Comments

Triangle is related to the tangent numbers A000182.

Examples

			Triangle begins:
     1;
     0,    1;
     2,    0,    2;
     0,    8,    0,    6;
    16,    0,   40,    0,    24;
     0,   136,   0,   240,    0,   120;
    272,   0,  1232,   0,   1680,   0,    720;
     0,  3968,   0,  12096,   0,  13440,   0,  5040;
   7936,   0,  56320,  0,  129024,  0,  120960,  0,   40320;
     0, 176896,  0, 814080,   0, 1491840,  0, 1209600,  0, 362880;
  353792,  0, 3610112, 0, 12207360, 0, 18627840, 0, 13305660, 0, 3628800;
  ...
		

References

  • S. Mukai, An Introduction to Invariants and Moduli, Cambridge, 2003; see p. 446.

Crossrefs

Similar to A104035. Leading edge is essentially A000182.
Cf. A003707.

Programs

  • Maple
    T:=proc(n,k) if k=-1 then 0 elif n=1 and k=1 then 1 elif k>n then 0 else (k-1)*T(n-1,k-1)+(k+1)*T(n-1,k+1) fi end: for n from 1 to 11 do seq(T(n,k),k=1..n) od; # yields sequence in triangular form [Produces triangle with a different offset] # Emeric Deutsch, Jun 13 2005

Formula

T(n, n) = n!; T(n, 0) = 0 if n = 2m+1; T(n, 0) = A000182(m+1) if n = 2m.
Sum_{k>=0} T(m, k)*T(n, k)*(k+1) = T(m+n, 0).
Sum_{k>=0} T(n, k) = |A003707(n+1)|.

Extensions

More terms from Emeric Deutsch, Jun 13 2005
Additional comments from Philippe Deléham, Sep 17 2005
Edited by N. J. A. Sloane, Aug 23 2008 at the suggestion of R. J. Mathar
Showing 1-10 of 10 results.