This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A039304 Number of distinct quadratic residues mod 7^n. 3
 1, 4, 22, 151, 1051, 7354, 51472, 360301, 2522101, 17654704, 123582922, 865080451, 6055563151, 42388942054, 296722594372, 2077058160601, 14539407124201, 101775849869404, 712430949085822, 4987016643600751, 34909116505205251 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,2 COMMENTS Number of distinct n-digit suffixes of base 7 squares. LINKS Vincenzo Librandi, Table of n, a(n) for n = 0..200 Index entries for linear recurrences with constant coefficients, signature (7,1,-7). FORMULA a(n) = floor( (7^n + 3)*7/16 ). G.f.: (1 - 3*x - 7*x^2)/((1-x)*(1+x)*(1-7*x)). - Colin Barker, Mar 08 2012 a(n) = 7*a(n-1) + a(n-2) - 7*a(n-3). - Vincenzo Librandi, Apr 21 2012 a(n) = A000224(7^n). - R. J. Mathar, Sep 28 2017 MAPLE A039304 := proc(n)     floor((7^n+3)*7/16) ; end proc: seq(A039304(n), n=0..10) ; # R. J. Mathar, Sep 28 2017 MATHEMATICA CoefficientList[Series[(1-3*x-7*x^2)/((1-x)*(1+x)*(1-7*x)), {x, 0, 40}], x] (* Vincenzo Librandi, Apr 21 2012 *) LinearRecurrence[{7, 1, -7}, {1, 4, 22}, 30] (* Harvey P. Dale, Aug 03 2016 *) PROG (MAGMA) [Floor((7^n+3)*7/16): n in [0..25]]; // Vincenzo Librandi, May 14 2011 (MAGMA) I:=[1, 4, 22]; [n le 3 select I[n] else 7*Self(n-1)+Self(n-2)-7*Self(n-3): n in [1..30]]; // Vincenzo Librandi, Apr 21 2012 CROSSREFS Cf. A000224, A000420 (7^n). Sequence in context: A228883 A307439 A189845 * A267219 A152404 A062817 Adjacent sequences:  A039301 A039302 A039303 * A039305 A039306 A039307 KEYWORD nonn,easy 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 | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified October 22 09:31 EDT 2019. Contains 328315 sequences. (Running on oeis4.)