login
Numbers m such that T(m) + 3*T(m+1) is a square, where T = A000217.
7

%I #72 Sep 08 2022 08:46:18

%S 3,143,4899,166463,5654883,192099599,6525731523,221682772223,

%T 7530688524099,255821727047183,8690408031080163,295218051329678399,

%U 10028723337177985443,340681375412721826703,11573138040695364122499,393146012008229658338303,13355391270239113019379843

%N Numbers m such that T(m) + 3*T(m+1) is a square, where T = A000217.

%C Equivalently, both m+1 and 2*m+3 are squares for nonnegative m.

%C Corresponding triangular numbers T(m): 6, 10296, 12002550, 13855048416, 15988853699286, 18451128064030200, 21292585958400815526, ...

%C Square roots of T(m) + 3*T(m+1) are listed by A082405 (after 0).

%C Negative values of m for which T(m) + 3*T(m+1) is a square: -1, -2, -26, -842, -28562, -970226, -32959082, ...

%H Colin Barker, <a href="/A278310/b278310.txt">Table of n, a(n) for n = 1..650</a>

%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (35,-35,1).

%F O.g.f.: x*(3 + 38*x - x^2)/((1 - x)*(1 - 34*x + x^2)).

%F E.g.f.: (exp((1-sqrt(2))^4*x) + exp((1+sqrt(2))^4*x) - 10*exp(x))/8 + 1.

%F a(n) = 35*a(n-1) - 35*a(n-2) + a(n-3) for n>3.

%F a(n) = 34*a(n-1) - a(n-2) + 40 for n>2.

%F a(n) = a(-n) = ((1 + sqrt(2))^(4*n) + (1 - sqrt(2))^(4*n))/8 - 5/4.

%F a(n) = 4*A001109(n)^2 - 1.

%F a(n) = -A029546(n) + 38*A029546(n-1) + 3*A029546(n-2) for n>1.

%F Lim_{n -> infinity} a(n)/a(n-1) = A156164.

%F Floor(sqrt(a(n))) = A182189(n) - 2.

%F a(n) - a(n-1) = 4*A046176(n) for n>1.

%e 3 is in the sequence because T(3) + 3*T(4) = 6 + 3*10 = 6^2.

%e For n=5 is a(5) = 5654883, therefore floor(sqrt(5654883)) = 2377 = A182189(5) - 2 = 2379 - 2.

%p P:=proc(q) local n; for n from 3 to q do if type(sqrt(2*n^2+5*n+3),integer) then print(n); fi; od; end: P(10^9); # _Paolo P. Lava_, Nov 18 2016

%t Table[((1 + Sqrt[2])^(4 n) + (1 - Sqrt[2])^(4 n))/8 - 5/4, {n, 1, 20}]

%t RecurrenceTable[{a[1] == 3, a[2] == 143, a[n] == 34 a[n - 1] - a[n - 2] + 40}, a, {n, 1, 20}]

%t LinearRecurrence[{35, -35, 1}, {3, 143, 4899}, 50] (* _G. C. Greubel_, Nov 20 2016 *)

%o (Sage)

%o def A278310():

%o a, b = 3, 143

%o yield a

%o while True:

%o yield b

%o a, b = b, 34*b - a + 40

%o a = A278310(); print([next(a) for _ in range(18)]) # _Peter Luschny_, Nov 18 2016

%o (PARI) Vec(x*(3 + 38*x - x^2)/((1 - x)*(1 - 34*x + x^2)) + O(x^50)) \\ _G. C. Greubel_, Nov 20 2016

%o (Magma) Iv:=[3,143]; [n le 2 select Iv[n] else 34*Self(n-1)-Self(n-2)+40: n in [1..20]];

%Y Subsequence of A000466.

%Y Cf. A000217, A001109, A029546, A046176, A082405, A156164, A182189.

%Y Cf. A278438: numbers m such that T(m) + 2*T(m+1) is a square.

%Y Cf. A078522: numbers m such that 3*T(m) + T(m+1) is a square.

%Y Cf. similar sequences with closed form ((1 + sqrt(2))^(4*r) + (1 - sqrt(2))^(4*r))/8 + k/4: A084703 (k=-1), A076218 (k=3), this sequence (k=-5).

%K nonn,easy

%O 1,1

%A _Bruno Berselli_, Nov 17 2016