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.

A269018 Primes p of the form 2^k + 2*(-1)^k - 1.

Original entry on oeis.org

2, 5, 17, 29, 257, 509, 65537, 536870909, 13164036458569648337239753460458804039861886925068638906788872189, 3369993333393829974333376885877453834204643052817571560137951281149, 13803492693581127574869511724554050904902217944340773110325048447598589
Offset: 1

Views

Author

Jaroslav Krizek, Feb 17 2016

Keywords

Comments

Corresponding values of k: 0, (2, 3), 4, 5, 8, 9, 16, 29, 213, 221, 233, ...; for the prime 5 there are two values: 2 and 3.
Fermat primes > 3 from A019434 are terms.
Prime terms from A269019.
Conjecture: union of {2}, {A019434(n) for n > 1} and {A176680(n)}.
a(16) > 2^16000 if it exists. - Robert Israel, Nov 11 2022
a(16) = 2^20757 - 3, a(17) = 2^30041 - 3. a(18) > 2^40000, if it exists. - Jon E. Schoenfield, Nov 11 2022

Crossrefs

Programs

  • Magma
    Set(Sort([2^n + 2*(-1)^n - 1: n in [0..300] | IsPrime(2^n + 2*(-1)^n - 1)]))
  • Maple
    Res:= 2,5: count:= 2:
    for n from 4 while count < 15 do
       x:= 2^n + 2*(-1)^n - 1;
       if isprime(x) then Res:= Res,x; count:= count+1  fi;
    od:
    Res; # Robert Israel, Nov 11 2022

A344920 The Worpitzky transform of the squares.

Original entry on oeis.org

0, -1, 5, -13, 29, -61, 125, -253, 509, -1021, 2045, -4093, 8189, -16381, 32765, -65533, 131069, -262141, 524285, -1048573, 2097149, -4194301, 8388605, -16777213, 33554429, -67108861, 134217725, -268435453, 536870909, -1073741821, 2147483645, -4294967293
Offset: 0

Views

Author

Peter Luschny, Jun 24 2021

Keywords

Comments

The Worpitzky transform maps a sequence A to a sequence B, where B(n) = Sum_{k=0..n} A163626(n, k)*A(k). (If A(n) = 1/(n + 1) then B(n) are the Bernoulli numbers (with B(1) = 1/2.))
Also row 2 in A371761. Can be generated by the signed Akiyama-Tanigawa algorithm for powers (see the Python script). - Peter Luschny, Apr 12 2024

Crossrefs

Up to shift and sign: even bisection A267921, odd bisection A141725.

Programs

  • Maple
    gf := (exp(x) - 1)*(exp(x) - 2)*exp(-2*x): ser := series(gf, x, 36):
    seq(n!*coeff(ser, x, n), n = 0..31);
  • Mathematica
    W[n_, k_] := (-1)^k k! StirlingS2[n + 1, k + 1];
    WT[a_, len_] := Table[Sum[W[n, k] a[k], {k, 0, n}], {n, 0, len-1}];
    WT[#^2 &, 32] (* The Worpitzky transform applied to the squares. *)
  • Python
    # Using the Akiyama-Tanigawa algorithm for powers from A371761.
    print([(-1)**n * v for (n, v) in enumerate(ATPowList(2, 32))])
    # Peter Luschny, Apr 12 2024

Formula

a(n) = n! * [x^n] (exp(x) - 1)*(exp(x) - 2)*exp(-2*x).
a(n) = (-1)^(n + 1)*(3 - 2^(n + 1)) for n >= 1. - Hugo Pfoertner, Jun 24 2021
a(n) = [x^n] x*(2*x - 1)/(2*x^2 + 3*x + 1). - Stefano Spezia, Jun 24 2021

A269019 a(n) = 2^n + 2*(-1)^n - 1.

Original entry on oeis.org

2, -1, 5, 5, 17, 29, 65, 125, 257, 509, 1025, 2045, 4097, 8189, 16385, 32765, 65537, 131069, 262145, 524285, 1048577, 2097149, 4194305, 8388605, 16777217, 33554429, 67108865, 134217725, 268435457, 536870909, 1073741825, 2147483645, 4294967297, 8589934589
Offset: 0

Views

Author

Jaroslav Krizek, Feb 17 2016

Keywords

Comments

Fermat numbers > 3 from A000215 are terms.
Prime terms are in A269018.
Union of A052539 and A267921.

Examples

			For n = 6; a(n) = 2^n + 2*(-1)^n - 1 = 2^6 + 2*(-1)^6 - 1 = 65.
		

Crossrefs

Programs

  • Magma
    [2^n + 2*(-1)^n - 1: n in [0..300]]
  • Mathematica
    Table [2^n + 2 (-1)^n - 1, {n, 0, 80}] (* or *) CoefficientList[Series[(2 - 5 x + 5 x^2) / ((1 - 2 x) (1 - x^2)), {x, 0, 33}], x] (* Vincenzo Librandi, Feb 18 2016 *)
    LinearRecurrence[{2,1,-2},{2,-1,5},40] (* Harvey P. Dale, Feb 25 2022 *)

Formula

G.f.: (2-5*x+5*x^2)/((1-2*x)*(1-x^2)). - Vincenzo Librandi, Feb 18 2016

A281500 Reduced denominators of f(n) = (n+1)/(2^(2+n)-2) with A026741(n+1) as numerators.

Original entry on oeis.org

2, 3, 14, 15, 62, 63, 254, 255, 1022, 1023, 4094, 4095, 16382, 16383, 65534, 65535, 262142, 262143, 1048574, 1048575, 4194302, 4194303, 16777214, 16777215, 67108862, 67108863, 268435454, 268435455, 1073741822, 1073741823, 4294967294, 4294967295, 17179869182, 17179869183
Offset: 0

Views

Author

Paul Curtz, Jan 23 2017

Keywords

Comments

f(n) = (n+1)/A000918(n+2) = 1/2, 2/6, 3/14, 4/30, 5/62, 6/126, 7/254, 8/510, 9/1022, 10/2046, 11/4094, 12/8190, ... .
Partial reduction: 1/2, 1/3, 3/14, 2/15, 5/62, 3/63, 7/254, 4/255, 9/1022, 5/1023, 11/4094, 6/4095, ... = A026741(n+1)/a(n).
Full reduction: 1/2, 1/3, 3/14, 2/15, 5/62, 1/21, 7/254, ... = A111701(n+1)/(2, 3, 14, 15, 62, 21, ... )
A164555(n+1)/A027642(n) = 1/2, 1/6, 0, -1/30, 0, 1/42, ... = f(n) * A198631(n)/A006519(n+1) = 1, 1/2, 0, -1/4, 0, 1/2, ... .).
Via f(n), we go from the second fractional Euler numbers to the second Bernoulli numbers.
a(n) mod 10: periodic sequence of length 4: repeat [2, 3, 4, 5].
a(n) differences table:
. 2, 3, 14, 15, 62, 63, 254, 255, ...
. 1, 11, 1, 47, 1, 191, 1, 767, ... see A198693
. 10, -10, 46, -46, 190, -190, 766, -766, ... see A096045, from Bernoulli(2n).
Extension of a(n): a(-2) = -1, a(-1) = 0.

Crossrefs

Programs

  • Mathematica
    a[n_] := (3+(-1)^n)*(2^(n+1)-1)/2; (* or *) a[n_] := If[EvenQ[n], 4^(n/2+1)-2, 4^((n+1)/2)-1]; Table[a[n], {n, 0, 35}] (* Jean-François Alcover, Jan 24 2017 *)
  • PARI
    Vec((2 + 3*x + 4*x^2) / ((1 - x)*(1 + x)*(1 - 2*x)*(1 + 2*x)) + O(x^50)) \\ Colin Barker, Jan 24 2017

Formula

From Colin Barker, Jan 24 2017: (Start)
G.f.: (2 + 3*x + 4*x^2) / ((1 - x)*(1 + x)*(1 - 2*x)*(1 + 2*x)).
a(n) = 5*a(n-2) - 4*a(n-4) for n>3. (End)
From Jean-François Alcover, Jan 24 2017: (Start)
a(n) = (3 + (-1)^n)*(2^(n + 1) - 1)/2.
a(n) = 4^((n + 1 + ((n + 1) mod 2))/2) - 1 - ((n + 1) mod 2). (End)
a(n) = a(n-2) + A117856(n+1) for n>1.
a(2*k) = 4^(k + 1) - 2, a(2*k+1) = a(2*k) + 1 = 4^(k+1) - 1.
a(2*k) + a(2*k+1) = A267921(k+1).
Showing 1-4 of 4 results.