login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A008853 Numbers n such that n^2 and n have same last 3 digits. 2
0, 1, 376, 625, 1000, 1001, 1376, 1625, 2000, 2001, 2376, 2625, 3000, 3001, 3376, 3625, 4000, 4001, 4376, 4625, 5000, 5001, 5376, 5625, 6000, 6001, 6376, 6625, 7000, 7001, 7376, 7625, 8000, 8001, 8376, 8625, 9000, 9001, 9376, 9625, 10000 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
REFERENCES
L. E. Dickson, History of the Theory of Numbers. Carnegie Institute Public. 256, Washington, DC, Vol. 1, 1919; Vol. 2, 1920; Vol. 3, 1923, see vol. 1, p. 459.
LINKS
FORMULA
a(4n)=1000*n, a(4n+1)=1000*n+1, a(4n+2)=1000*n+376, a(4n+3)=1000*n+625. - Franklin T. Adams-Watters, Mar 13 2006
From G. C. Greubel, Sep 13 2019: (Start)
a(n) = a(n-1) + a(n-4) - a(n-5).
G.f.: x^2*(1 +375*x +249*x^2 +375*x^3)/((1-x)*(1-x^4)). (End)
MAPLE
for n to 10000 do if n^2 - n mod 1000 = 0 then print(n); fi; od;
MATHEMATICA
LinearRecurrence[{1, 0, 0, 1, -1}, {0, 1, 376, 625, 1000}, 60] (* G. C. Greubel, Sep 13 2019 *)
PROG
(PARI) my(x='x+O('x^60)); concat([0], Vec(x*(1 +375*x +249*x^2 +375*x^3)/((1-x)*(1-x^4)))) \\ G. C. Greubel, Sep 13 2019
(Magma) R<x>:=PowerSeriesRing(Integers(), 60); [0] cat Coefficients(R!( x*(1 +375*x +249*x^2 +375*x^3)/((1-x)*(1-x^4)) )); // G. C. Greubel, Sep 13 2019
(Sage) [n for n in (0..1250) if mod(n, 1000)==mod(n^2, 1000)] # G. C. Greubel, Sep 13 2019
(GAP) a:=[0, 1, 376, 625, 1000];; for n in [6..60] do a[n]:=a[n-1]+a[n-4]-a[n-5]; od; a; # G. C. Greubel, Sep 13 2019
CROSSREFS
Sequence in context: A251645 A259769 A238231 * A188007 A251644 A234916
KEYWORD
nonn,easy,base
AUTHOR
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 15:57 EDT 2024. Contains 371961 sequences. (Running on oeis4.)