OFFSET
1,2
COMMENTS
Also positive integers y in the solutions to 5*x^2 - 8*y^2 - 3*x + 8*y - 2 = 0, the corresponding values of x being A046195.
LINKS
Colin Barker, Table of n, a(n) for n = 1..950
Index entries for linear recurrences with constant coefficients, signature (1,0,1442,-1442,0,-1,1).
FORMULA
a(n) = a(n-1)+1442*a(n-3)-1442*a(n-4)-a(n-6)+a(n-7).
G.f.: x*(4*x^5+34*x^4+721*x^3-34*x^2-4*x-1) / ((x-1)*(x^6-1442*x^3+1)).
EXAMPLE
5 is in the sequence because the 5th centered octagonal number is 81, which is also the 6th heptagonal number.
MATHEMATICA
CoefficientList[Series[(4 x^5 + 34 x^4 + 721 x^3 - 34 x^2 -4 x - 1)/((x-1) (x^6 - 1442 x^3 + 1)), {x, 0, 30}], x] (* Vincenzo Librandi, Jan 20 2015 *)
LinearRecurrence[{1, 0, 1442, -1442, 0, -1, 1}, {1, 5, 39, 760, 6494, 55518, 1095199}, 20] (* Harvey P. Dale, Jul 04 2017 *)
PROG
(PARI) Vec(x*(4*x^5+34*x^4+721*x^3-34*x^2-4*x-1)/((x-1)*(x^6-1442*x^3+1)) + O(x^100))
(Magma) I:=[1, 5, 39, 760, 6494, 55518, 1095199]; [n le 7 select I[n] else Self(n-1)+1442*Self(n-3)-1442*Self(n-4)-Self(n-6)+Self(n-7): n in [1..25]]; // Vincenzo Librandi, Jan 20 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Colin Barker, Jan 19 2015
EXTENSIONS
Corrected by Vincenzo Librandi, Jan 20 2015
STATUS
approved