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

A038521 Number of elements of GF(2^n) with trace 1 and subtrace 1.

Original entry on oeis.org

0, 0, 2, 1, 4, 10, 12, 36, 64, 120, 272, 496, 1024, 2080, 4032, 8256, 16384, 32640, 65792, 130816, 262144, 524800, 1047552, 2098176, 4194304, 8386560, 16781312, 33550336, 67108864, 134225920, 268419072, 536887296, 1073741824, 2147450880, 4295032832, 8589869056
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    I:=[0,0,2,1]; [m le 4 select I[m] else  2*Self(m-2) + 4*Self(m-3): m in [1..33]]; // Marius A. Burtea, Aug 02 2019
  • Maple
    A038521 := proc(n) local r,a,i ; if n mod 2 = 1 then r := 3 ; else r := 1 ; fi; a :=0 ; for i from r to n by 4 do a := a+binomial(n,i) ; od; a ; end: for n from 0 to 40 do printf("%d,",A038521(n)) ; od: # R. J. Mathar, Oct 20 2008
  • Mathematica
    LinearRecurrence[{0, 2, 4}, {0, 0, 2, 1}, 33] (* Jean-François Alcover, May 08 2023 *)
  • PARI
    concat([0, 0], Vec(x*(2 + x) / ((1 - 2*x)*(1 + 2*x + 2*x^2)) + O(x^35))) \\ Colin Barker, Aug 02 2019
    

Formula

a(n) = C(n, r+0) + C(n, r+4) + C(n, r+8) + ... where r = 3 if n odd, r = 1 if n even.
a(n) = (2^(n-1) - A108520(n-1))/2 if n > 0. - R. J. Mathar, Jan 29 2008
From Colin Barker, Aug 02 2019: (Start)
G.f.: x^2*(2 + x) / ((1 - 2*x)*(1 + 2*x + 2*x^2)).
a(n) = ((-1-i)^(n-2) + (-1+i)^(n-2) + 2^(n-1)) / 2 = 2*A176739(n-2) + A176739(n-3).
a(n) = 2*a(n-2) + 4*a(n-3) for n>3.
(End)

Extensions

Values duplicated A038520 and were replaced by R. J. Mathar, Oct 20 2008
Missing a(0) = 0 inserted by Andrey Zabolotskiy, Nov 12 2024

A038518 Number of elements of GF(2^n) with trace 0 and subtrace 0.

Original entry on oeis.org

0, 1, 1, 1, 6, 6, 16, 36, 56, 136, 256, 496, 1056, 2016, 4096, 8256, 16256, 32896, 65536, 130816, 262656, 523776, 1048576, 2098176, 4192256, 8390656, 16777216, 33550336, 67117056, 134209536, 268435456, 536887296, 1073709056, 2147516416
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    0,seq(1/4*2^k-1/4*(-1-I)^k-1/4*(-1+I)^k,k=1..40); seq(coeff(convert(series((-x^3+x^2+x)/((1-2*x)*(1+2*x+2*x^2)),x,50),polynom),x,i),i=0..40); # C. Ronaldo (aga_new_ac(AT)hotmail.com), Dec 16 2004
  • Mathematica
    LinearRecurrence[{0,2,4},{0,1,1,1},40] (* Harvey P. Dale, Mar 31 2020 *)
  • PARI
    concat(0, Vec(x*(1 + x - x^2) / ((1 - 2*x)*(1 + 2*x + 2*x^2)) + O(x^40))) \\ Colin Barker, Aug 02 2019

Formula

C(n, r+0)+C(n, r+4)+C(n, r+8)+... where r = 0 if n odd, r = 2 if n even.
G.f.: (-x^3+x^2+x)/[(1-2x)(1+2x+2x^2)].
a(0)=0; a(n) = ( 2^n - (-1-i)^n - (-1+i)^n )/4, i=sqrt(-1). - C. Ronaldo (aga_new_ac(AT)hotmail.com), Dec 16 2004
a(n) = 2*a(n-2) + 4*a(n-3) for n>3. - Colin Barker, Aug 02 2019

A038520 Number of elements of GF(2^n) with trace 1 and subtrace 0.

Original entry on oeis.org

0, 1, 0, 3, 4, 6, 20, 28, 64, 136, 240, 528, 1024, 2016, 4160, 8128, 16384, 32896, 65280, 131328, 262144, 523776, 1049600, 2096128, 4194304, 8390656, 16773120, 33558528, 67108864, 134209536, 268451840, 536854528, 1073741824
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{0,2,4},{0,1,0,3},40] (* Harvey P. Dale, Oct 15 2017 *)
  • PARI
    concat(0, Vec(x*(1 + x^2) / ((1 - 2*x)*(1 + 2*x + 2*x^2)) + O(x^40))) \\ Colin Barker, Aug 02 2019

Formula

a(n) = C(n, r+0)+C(n, r+4)+C(n, r+8)+... where r = 1 if n odd, r = 3 if n even.
a(n) = 2*a(n-2) + 4*a(n-3), n > 3. - Paul Curtz, Feb 06 2008
From Colin Barker, Aug 02 2019: (Start)
G.f.: x*(1 + x^2) / ((1 - 2*x)*(1 + 2*x + 2*x^2)).
a(n) = (2^n + i*((-1-i)^n - (-1+i)^n)) / 4 for n>0, where i=sqrt(-1).
(End)
Showing 1-3 of 3 results.