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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A221671 Maximum number of squares in a non-constant arithmetic progression (AP) of length n. 5
1, 2, 3, 3, 4, 4, 4, 5, 5, 5, 5, 5, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Let s(n;d,i) denote the number of squares in AP i, i+d, i+2d, ..., i+(n-1)d. Then a(n) is the maximum of s(n;d,i) over all such APs with d > 0.

González-Jiménez and Xarles (2013) compute a(n) up to a(52) = 12 using elliptic curves (see Table 2, where their Q(N) = a(N)). They do not seem to have noticed that a(n) = A193832(n) for n != 5 in the range where they computed a(n). I conjecture that this formula holds for all n != 5.

LINKS

Table of n, a(n) for n=1..52.

Enrique González-Jiménez and Xavier Xarles, On a conjecture of Rudin on squares in Arithmetic Progressions, arXiv 2013.

FORMULA

a(n) = A193832(n) for n < 53 except for n = 5.

a(n) >= A193832(n) for all n. (Proof. A193832 equals the partial sums of A080995 (characteristic function of generalized pentagonal numbers A001318) and a term in the AP 1+24*k is a square if and only if k = A001318(x) = x*(3*x-1)/2 for some x. See González-Jiménez and Xarles (2013) Lemma 2.)

a(A221672(n)) = n.

EXAMPLE

The AP 1, 25, 49 = 1^2, 5^2, 7^2 shows that a(3) = 3. By Fermat and Euler, no four squares are in AP, so a(4) = 3 (see A216869). Then the AP 49, 169, 289, 409, 529 = 7^2, 13^2, 17^2, 409, 23^2 shows that a(5) = 4 (see A216870).

MATHEMATICA

(* note that an extension to more than 52 terms may not be correct *) row[n_] := Join[Table[2*n-1, {2*n-1}], Table[2*n, {n}]]; row[2] = {3, 3, 4, 4, 4}; Flatten[Table[row[n], {n, 1, 6}]][[1 ;; 52]] (* Jean-François Alcover, Jan 25 2013, from formula *)

CROSSREFS

Cf. A001318, A080995, A193832, A216869, A216870, A221672.

Sequence in context: A257569 A039836 A083398 * A301640 A061420 A003057

Adjacent sequences:  A221668 A221669 A221670 * A221672 A221673 A221674

KEYWORD

nonn,hard,more

AUTHOR

Jonathan Sondow, Jan 24 2013

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 20 22:22 EDT 2019. Contains 322310 sequences. (Running on oeis4.)