OFFSET
1,1
COMMENTS
The identity (80000*n^2-120800*n+45601)^2-(100*n.^2-151*n+57)*(8000*n-6040)^2=1 can be written as A157628(n)^2-a(n)*A157627(n)^2=1.
The continued fraction expansion of sqrt(a(n)) is [10n-8; {2, 4, 2, 20n-16}]. For n=1, this collapses to [2; {2, 4}]. - Magus K. Chu, Sep 05 2022
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..10000
Vincenzo Librandi, X^2-AY^2=1
Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
FORMULA
a(n) = 3*a(n-1) -3*a(n-2) +a(n-3).
G.f.: x*(-6-137*x-57*x^2)/(x-1)^3.
MATHEMATICA
LinearRecurrence[{3, -3, 1}, {6, 155, 504}, 40]
PROG
(Magma) I:=[6, 155, 504]; [n le 3 select I[n] else 3*Self(n-1)-3*Self(n-2)+1*Self(n-3): n in [1..40]];
(PARI) a(n) = 100*n^2 - 151*n + 57.
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vincenzo Librandi, Mar 03 2009
STATUS
approved