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

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A008959 Final digits of squares: n^2 mod 10. 13
0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,3

COMMENTS

a(m*n)=a(m)*a(n) mod 10; a(5*n+k)=a(5*n-k) for k<=5*n. [From Reinhard Zumkeller, Apr 24 2009]

a(n) = n^6 mod 10. [From Zerinvary Lajos (zerinvarylajos(AT)yahoo.com), Nov 06 2009]

a(n) = A002015(n) mod 10 = A174452(n) mod 10. [From Reinhard Zumkeller, Mar 21 2010]

Decimal expansion of 166285490/1111111111. - Alexander R. Povolotsky, Mar 09 2013

LINKS

Harvey P. Dale, Table of n, a(n) for n = 0..1000

Index entries for sequences related to final digits of numbers

Index to sequences with linear recurrences with constant coefficients, signature (0,0,0,0,0,0,0,0,0,1).

FORMULA

Periodic with period 10. - Franklin T. Adams-Watters, Mar 13 2006

a(n)=1/5*{(n mod 10)+2*[(n+1) mod 10]+3*[(n+2) mod 10]-[(n+3) mod 10]+[(n+5) mod 10]+2*[(n+6) mod 10]-2*[(n+7) mod 10]-[(n+8) mod 10]} - Paolo P. Lava, Nov 24 2006

a(n)=4.5 - (1 + 5^(1/2))*cos(Pi*n/5) + ( - 1 - 3/5*5^(1/2))*cos(2*Pi*n/5) + (5^(1/2) - 1)*cos(3*Pi*n/5) + ( - 1 + 3/5*5^(1/2))*cos(4*Pi*n/5) - 0.5*( - 1)^n [From Richard Choulet, Dec 12 2008]

a(n) = A010879(A000290(n)). [Reinhard Zumkeller, Jan 04 2009]

G.f.: (x^9+4*x^8+9*x^7+6*x^6+5*x^5+6*x^4+9*x^3+4*x^2+x)/(-x^10+1). [Colin Barker, Aug 14 2012]

MATHEMATICA

Table[Mod[n^2, 10], {n, 0, 200}] (* From Vladimir Joseph Stephan Orlovsky, Apr 21 2011 *)

PowerMod[Range[0, 80], 2, 10] (* or *) LinearRecurrence[{0, 0, 0, 0, 0, 0, 0, 0, 0, 1}, {0, 1, 4, 9, 6, 5, 6, 9, 4, 1}, 120] (* Harvey P. Dale, Oct 16 2012 *)

PROG

(Sage) [power_mod(n, 2, 10) for n in xrange(0, 81)] # [From Zerinvary Lajos (zerinvarylajos(AT)yahoo.com), Nov 06 2009]

(MAGMA) [0] cat [Intseq(n^2)[1]: n in [1..80]]; // Bruno Berselli, Feb 14 2013

CROSSREFS

Cf. A070431, A070435, A070438, A070442, A070452, A159852, A000290. [Reinhard Zumkeller, Apr 24 2009]

Sequence in context: A094090 A200632 A186723 * A169917 A059729 A184988

Adjacent sequences:  A008956 A008957 A008958 * A008960 A008961 A008962

KEYWORD

nonn,easy,base

AUTHOR

N. J. A. Sloane.

STATUS

approved

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

Content is available under The OEIS End-User License Agreement .

Last modified May 19 23:59 EDT 2013. Contains 225436 sequences.