login
This site is supported by donations to The OEIS Foundation.

 

Logo

Annual appeal: Please make a donation to keep the OEIS running! Over 6000 articles have referenced us, often saying "we discovered this result with the help of the OEIS".
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A070386 a(n) = 5^n mod 39. 1
1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1, 5, 25, 8, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

LINKS

G. C. Greubel, Table of n, a(n) for n = 0..1000

Index entries for linear recurrences with constant coefficients, signature (0,0,0,1). [R. J. Mathar, Apr 20 2010]

FORMULA

a(n) = (1/8)*(27*(n mod 4)+47*((n+1) mod 4)-27*((n+2) mod 4)+5*((n+3) mod 4)). - Paolo P. Lava, Apr 16 2010

From R. J. Mathar, Apr 20 2010: (Start)

a(n) = a(n-4).

G.f.: ( -1-5*x-25*x^2-8*x^3 ) / ( (x-1)*(1+x)*(x^2+1) ). (End)

a(n) = (13*(-1)^n-3*((8+i)*(-i)^n+(8-i)*i^n)+39)/4, where i=sqrt(-1). - Bruno Berselli, Feb 07 2011

E.g.f.: (1/2)*(26*cosh(x) + 13*sinh(x) - 24*cos(x) - 3*sin(x)). - G. C. Greubel, Mar 16 2016

MATHEMATICA

PowerMod[5, Range[0, 120], 39] (* or *) PadRight[{}, 120, {1, 5, 25, 8}] (* Harvey P. Dale, Nov 19 2014 *)

PROG

(Sage) [power_mod(5, n, 39) for n in xrange(0, 93)] # Zerinvary Lajos, Nov 26 2009

(PARI) a(n) = lift(Mod(5, 39)^n); \\ Altug Alkan, Mar 16 2016

CROSSREFS

Sequence in context: A070387 A123748 A050108 * A050084 A070379 A143254

Adjacent sequences:  A070383 A070384 A070385 * A070387 A070388 A070389

KEYWORD

nonn,easy

AUTHOR

N. J. A. Sloane, May 12 2002

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified November 21 13:53 EST 2017. Contains 295001 sequences.