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.

A047315 Numbers that are congruent to {2, 4, 5, 6} mod 7.

Original entry on oeis.org

2, 4, 5, 6, 9, 11, 12, 13, 16, 18, 19, 20, 23, 25, 26, 27, 30, 32, 33, 34, 37, 39, 40, 41, 44, 46, 47, 48, 51, 53, 54, 55, 58, 60, 61, 62, 65, 67, 68, 69, 72, 74, 75, 76, 79, 81, 82, 83, 86, 88, 89, 90, 93, 95, 96, 97, 100, 102, 103, 104, 107, 109, 110, 111
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [n : n in [0..150] | n mod 7 in [2, 4, 5, 6]]; // Wesley Ivan Hurt, Jun 03 2016
  • Maple
    A047315:=n->(14*n-1-I^(2*n)-(3-I)*I^(-n)-(3+I)*I^n)/8: seq(A047315(n), n=1..100); # Wesley Ivan Hurt, Jun 03 2016
  • Mathematica
    Table[(14n-1-I^(2n)-(3-I)*I^(-n)-(3+I)*I^n)/8, {n, 80}] (* Wesley Ivan Hurt, Jun 03 2016 *)
    Select[Range[200],MemberQ[{2,4,5,6},Mod[#,7]]&] (* or *) LinearRecurrence[ {1,0,0,1,-1},{2,4,5,6,9},100] (* Harvey P. Dale, Jan 19 2019 *)

Formula

G.f.: x*(2+2*x+x^2+x^3+x^4) / ( (1+x)*(x^2+1)*(x-1)^2 ). - R. J. Mathar, Dec 03 2011
From Wesley Ivan Hurt, Jun 03 2016: (Start)
a(n) = a(n-1) + a(n-4) - a(n-5) for n>5.
a(n) = (14*n-1-i^(2*n)-(3-i)*i^(-n)-(3+i)*i^n)/8 where i=sqrt(-1).
a(2k) = A047288(k), a(2k-1) = A047385(k). (End)