login
A271713
Numbers n such that 3*n - 5 is a square.
6
2, 3, 7, 10, 18, 23, 35, 42, 58, 67, 87, 98, 122, 135, 163, 178, 210, 227, 263, 282, 322, 343, 387, 410, 458, 483, 535, 562, 618, 647, 707, 738, 802, 835, 903, 938, 1010, 1047, 1123, 1162, 1242, 1283, 1367, 1410, 1498, 1543, 1635, 1682, 1778, 1827, 1927, 1978, 2082, 2135, 2243, 2298
OFFSET
1,1
COMMENTS
Quasipolynomial of order 2 and degree 2. - Charles R Greathouse IV, Apr 12 2016
From Ray Chandler, Apr 13 2016: (Start)
Square roots of resulting squares gives A001651.
Sequence is the union of A141631 and A271740. (End)
FORMULA
G.f.: x*(2 + x + x^3 + 2*x^4)/((1 - x)^3*(1 + x)^2). - Ilya Gutkovskiy, Apr 12 2016
a(n) = (3/2)*n^2 + O(n). - Charles R Greathouse IV, Apr 12 2016
a(n) = a(n-1) + 2*a(n-2) - 2*a(n-3) - a(n-4) + a(n-5) for n>5. - Wesley Ivan Hurt, Apr 13 2016
EXAMPLE
a(3) = 7 because 3*7 - 5 = 16 = 4^2.
MAPLE
A271713:=n->`if`(issqr(3*n-5), n, NULL): seq(A271713(n), n=1..5000); # Wesley Ivan Hurt, Apr 13 2016
MATHEMATICA
Select[Range@ 2300, IntegerQ@ Sqrt[3 # - 5] &] (* Michael De Vlieger, Apr 12 2016 *)
PROG
(Magma) [ n: n in [0..2500] | IsSquare(3*n - 5)];
(PARI) is(n)=issquare(3*n-5) \\ Charles R Greathouse IV, Apr 12 2016
(PARI) a(n)=((n\2*3-(-1)^n)^2+5)/3 \\ Charles R Greathouse IV, Apr 12 2016
(Python)
from __future__ import division
A271713_list = [(n**2+5)//3 for n in range(10**6) if not (n**2+5) % 3] # Chai Wah Wu, Apr 13 2016
CROSSREFS
Cf. numbers n such that 3*n + k is a square: A120328 (k=-6), this sequence (k=-5), A056107 (k=-3), A257083 (k=-2), A033428 (k=0), A001082 (k=1), A080663 (k=3), A271675 (k=4), A100536 (k=6).
Sequence in context: A024832 A213075 A100847 * A355726 A356364 A173132
KEYWORD
nonn,easy
AUTHOR
STATUS
approved