login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A165903 a(n) = (a(n-1)^2 + a(n-2)^2 + a(n-1)*a(n-2))/a(n-3) with three initial ones. 6

%I #25 Oct 24 2022 12:27:13

%S 1,1,1,3,13,217,16693,21717363,2175145909081,283430597537694797281,

%T 3699017428454717709381715649628841,

%U 6290488320295607125006566146327310005599469877825552723

%N a(n) = (a(n-1)^2 + a(n-2)^2 + a(n-1)*a(n-2))/a(n-3) with three initial ones.

%H Seiichi Manyama, <a href="/A165903/b165903.txt">Table of n, a(n) for n = 0..17</a>

%F a(n) ~ 1/6 * c^(((1+sqrt(5))/2)^n), where c = 1.902254978346365075882696720546123493664... . - _Vaclav Kotesovec_, May 06 2015

%F a(n) = 6*a(n-1)*a(n-2)-a(n-1)-a(n-2)-a(n-3). - _Bruno Langlois_, Aug 21 2016

%p a:= proc(n, k) option remember;

%p if n<3 then 1

%p else (a(n-1)^2 + a(n-2)^2 + a(n-1)*a(n-2))/a(n-3)

%p fi; end:

%p seq( a(n), n=0..12); # _G. C. Greubel_, Dec 19 2019

%t RecurrenceTable[{a[0]==1,a[1]==1,a[2]==1, a[n]==(a[n-1]^2+a[n-2]^2+a[n-1]*a[n-2])/a[n-3]},a,{n,0,10}] (* _Vaclav Kotesovec_, May 06 2015 *)

%t nxt[{a_,b_,c_}]:={b,c,(c^2+b^2+b*c)/a}; NestList[nxt,{1,1,1},10][[All,1]] (* _Harvey P. Dale_, Oct 24 2022 *)

%o (PARI) a(n)=if(n<3,1,(a(n-1)^2 +a(n-2)^2 +a(n-1)*a(n-2))/a(n-3))

%o (Magma) I:=[1,1,1]; [n le 3 select I[n] else (Self(n-1)^2 + Self(n-2)^2 + Self(n-1)*Self(n-2))/Self(n-3): n in [1..12]]; // _G. C. Greubel_, Dec 19 2019

%o (Sage)

%o @CachedFunction

%o def a(n):

%o if (n<3): return 1

%o else: return (a(n-1)^2+a(n-2)^2+a(n-1)*a(n-2))/a(n-3)

%o [a(n) for n in (0..12)] # _G. C. Greubel_, Dec 19 2019

%o (GAP) a:=[1,1,1];; for n in [4..12] do a[n]:= (a[n-1]^2 + a[n-2]^2 + a[n-1]*a[n-2])/a[n-3]; od; a; # _G. C. Greubel_, Dec 19 2019

%Y Cf. A064098, A072882, A165896.

%K nonn

%O 0,4

%A _Jaume Oliver Lafont_, Sep 29 2009

%E "frac" keyword removed by _Jaume Oliver Lafont_, Oct 13 2009

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 6 15:21 EDT 2024. Contains 372294 sequences. (Running on oeis4.)