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.

A024014 2^n-n^4.

Original entry on oeis.org

1, 1, -12, -73, -240, -593, -1232, -2273, -3840, -6049, -8976, -12593, -16640, -20369, -22032, -17857, 0, 47551, 157168, 393967, 888576, 1902671, 3960048, 8108767, 16445440, 33163807, 66651888, 133686287, 267820800, 536163631, 1072931824
Offset: 0

Views

Author

Keywords

Crossrefs

Cf. sequences of the form k^n-n^4: this sequence (k=2), A024027 (k=3), A024040 (k=4), A024053 (k=5), A024066 (k=6), A024079 (k=7), A024092 (k=8), A024105 (k=9), A024118 (k=10), A024131 (k=11), A024144 (k=12).

Programs

  • Magma
    [2^n-n^4: n in [0..30]]; // Vincenzo Librandi, Apr 29 2011
    
  • Magma
    I:=[1,1,-12,-73,-240,-593]; [n le 6 select I[n] else 7*Self(n-1)-20*Self(n-2)+30*Self(n-3)-25*Self(n-4)+11*Self(n-5)-2*Self(n-6): n in [1..35]]; // Vincenzo Librandi, Oct 06 2014
  • Maple
    seq(2^n-n^4, n=0..100); # Robert Israel, Oct 06 2014
  • Mathematica
    Table[2^n-n^4,{n,0,100}]
    CoefficientList[Series[(1 - 6 x + x^2 + x^3 + 26 x^4 + x^5)/((1 - 2 x) (1 - x)^5), {x, 0, 30}], x] (* Vincenzo Librandi, Oct 06 2014 *)

Formula

G.f.: (1-6*x+x^2+x^3+26*x^4+x^5) / ((1-2*x)*(1-x)^5). - Vincenzo Librandi, Oct 06 2014
a(n) = 7*a(n-1) -20*a(n-2) +30*a(n-3) -25*a(n-4) +11*a(n-5) -2*a(n-6) for n>5. - Vincenzo Librandi, Oct 06 2014
E.g.f.: exp(2*x) - (x + 7*x^2 + 6*x^3 + x^4)* exp(x). - Robert Israel, Oct 06 2014

A215892 a(n) = 2^n - n^k, where k is the largest integer such that 2^n >= n^k.

Original entry on oeis.org

0, 5, 0, 7, 28, 79, 192, 431, 24, 717, 2368, 5995, 13640, 29393, 0, 47551, 157168, 393967, 888576, 1902671, 3960048, 1952265, 8814592, 23788807, 55227488, 119868821, 251225088, 516359763, 344741824, 1259979967, 3221225472, 7298466623, 15635064768
Offset: 2

Views

Author

Alex Ratushnyak, Aug 25 2012

Keywords

Examples

			a(2) = 2^2 - 2^2 = 0,
a(3) = 2^3 - 3 = 5,
a(4) = 2^4 - 4^2 = 0,
a(5) = 2^5 - 5^2 = 7,
a(6)..a(9) are 2^n - n^2,
a(10)..a(15) are 2^n - n^3,
a(16)..a(22) are 2^n - n^4, and so on.
		

Crossrefs

Programs

  • Magma
    [2^n - n^Floor(n*Log(n, 2)): n in [2..40]]; // Vincenzo Librandi, Jan 14 2019
  • Mathematica
    Table[2^n - n^Floor[n*Log[n, 2]], {n, 2, 35}] (* T. D. Noe, Aug 27 2012 *)
  • Python
    for n in range(2,100):
        a = 2**n
        k = 0
        while n**(k+1) <= a:
            k += 1
        print(a - n**k, end=',')
    

Formula

a(n) = 2^n - n^floor(n*log_n(2)), where log_n is the base-n logarithm.
Showing 1-2 of 2 results.