%I #43 Jan 03 2022 11:13:30
%S 3,37,587,9853,167123,2839957,48275867,820679533,13951521443,
%T 237175772677,4031987859947,68543792792413,1165244474990963,
%U 19809156067406197,336755653123584827,5724846103033980493,97322383751376783683,1654480523772802668517
%N a(n) = 3^n + 2 * 17^n for n >= 0.
%C This sequence was the subject of the 1st problem of the 27th British Mathematical Olympiad in 1991 (see the link BMO).
%C Proposition: a(n) is never a perfect square.
%C Proof (by induction): the unit digits of a(n) follow the pattern 3773, 3773, ...
%C Generalization: Steve Dinh proves that for nonnegative integers k, m, u and v, the numbers (10^k*u + 3)^n + 2*(10^m*v + 7)^n are never a perfect square for n >= 0 (see reference). - _Bernard Schott_, Dec 27 2021
%D S. Dinh, The Hard Mathematical Olympiad Problems And Their Solutions, AuthorHouse, 2011, Problem 1 of British Mathematical Olympiad 1991, page 186.
%D A. Gardiner, The Mathematical Olympiad Handbook: An Introduction to Problem Solving, Oxford University Press, 1997, reprinted 2011, Problem 1 pp. 57 and 115 (1991).
%H Colin Barker, <a href="/A333385/b333385.txt">Table of n, a(n) for n = 0..800</a>
%H British Mathematical Olympiad, <a href="https://bmos.ukmt.org.uk/home/bmo-1991.pdf">Problem 1</a>, 1991.
%H <a href="/index/O#Olympiads">Index to sequences related to Olympiads</a>.
%H <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (20,-51).
%F a(n) = A000244(n) + 2 * A001026(n).
%F From _Colin Barker_, Mar 18 2020: (Start)
%F G.f.: (3 - 23*x) / ((1 - 3*x)*(1 - 17*x)).
%F a(n) = 20*a(n-1) - 51*a(n-2) for n>1.
%F (End)
%e a(4) = 3^4 + 2 * 17^4 = 167123 = 7 * 19 * 1031 is not a perfect square.
%p S:=seq(3^n+2*17^n, n=0..40);
%t a[n_] := 3^n + 2 * 17^n ; Array[a, 18, 0] (* _Amiram Eldar_, Mar 18 2020 *)
%o (PARI) Vec((3 - 23*x) / ((1 - 3*x)*(1 - 17*x)) + O(x^20)) \\ _Colin Barker_, Mar 18 2020
%Y Cf. A000244 (3^n), A001026 (17^n), A330770.
%Y Subsequence of A000037.
%K nonn,easy
%O 0,1
%A _Bernard Schott_, Mar 18 2020