A065100 a(n+2) = 9*a(n+1) - a(n), a(0) = 3, a(1) = 27.
3, 27, 240, 2133, 18957, 168480, 1497363, 13307787, 118272720, 1051146693, 9342047517, 83027280960, 737903481123, 6558104049147, 58285032961200, 518007192601653, 4603779700453677, 40916010111481440, 363640311302879283
Offset: 0
Examples
From _Vincenzo Librandi_, Aug 07 2010: (Start) a(2) = 9*27 - 3 = 240; a(3) = 9*240 - 27 = 2133; a(4) = 9*2133 - 240 = 18957. (End)
Links
- Harry J. Smith, Table of n, a(n) for n = 0..100
- Tanya Khovanova, Recursive Sequences
- J.-P. Ehrmann et al., Problem POLYA002, Integer pairs (x,y) for which (x^2+y^2)/(1+pxy) is an integer.
- Index entries for linear recurrences with constant coefficients, signature (9,-1).
Crossrefs
Cf. A052530 (analog for c = 2).
Programs
-
Mathematica
a[0] = c; a[1] = p*c^3; a[n_] := a[n] = p*c^2*a[n - 1] - a[n - 2]; p = 1; c = 3; Table[ a[n], {n, 0, 20} ] LinearRecurrence[{9,-1},{3,27},30] (* Harvey P. Dale, Sep 22 2016 *)
-
PARI
polya002(1,3,20) \\ See A052530 for definition of function polya002().
-
PARI
{ p=1; c=3; k=p*c^2; for (n=0, 100, if (n>1, a=k*a1 - a2; a2=a1; a1=a, if (n, a=a1=k*c, a=a2=c)); write("b065100.txt", n, " ", a) ) } \\ Harry J. Smith, Oct 07 2009
Formula
G.f.: 3/(1 - 9*x + x^2). - Floor van Lamoen, Feb 07 2002
a(n) = 3*A018913(n+1). - R. J. Mathar, Oct 26 2009
a(n) = 9*a(n-1) - a(n-2) (with a(0)=3, a(1)=27). - Vincenzo Librandi, Aug 07 2010
E.g.f.: 3*exp(9*x/2)*(77*cosh(sqrt(77)*x/2) + 9*sqrt(77)*sinh(sqrt(77)*x/2))/77. - Stefano Spezia, Feb 23 2025
Extensions
Definition simplified by M. F. Hasler, Jun 12 2019
Comments