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.

A070352 a(n) = 3^n mod 5; or period 4, repeat [1, 3, 4, 2].

Original entry on oeis.org

1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, 1
Offset: 0

Views

Author

N. J. A. Sloane, May 12 2002

Keywords

Comments

Residues mod 5 of Lucas numbers: for n>=1, a(n-1) = A000032(n) mod 5. - Clark Kimberling, Aug 28 2008

Crossrefs

Cf. A000032. - Clark Kimberling, Aug 28 2008

Programs

Formula

From R. J. Mathar, Apr 13 2010: (Start)
a(n) = a(n-1) - a(n-2) + a(n-3) for n>2.
G.f.: (1+2*x+2*x^2) / ((1-x)*(1+x^2)). (End)
a(n) = 2^(3*n) mod 5. - Gary Detlefs, May 18 2014
E.g.f.: (1/2)*(5*exp(x) + sin(x) - 3*cos(x)). - G. C. Greubel, Mar 11 2016
a(n) = a(n-4) for n>3. - Wesley Ivan Hurt, Jul 09 2016