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!)
A274951 Pisot sequence E(8,12), a(n) = floor( a(n-1)^2/a(n-2) + 1/2 ). 1

%I #11 Aug 06 2016 15:31:28

%S 8,12,18,27,41,62,94,143,218,332,506,771,1175,1791,2730,4161,6342,

%T 9666,14732,22453,34221,52157,79494,121159,184662,281449,428965,

%U 653799,996476,1518761,2314792,3528048,5377210,8195577,12491140,19038144,29016641,44225186,67405013,102734125,156580349

%N Pisot sequence E(8,12), a(n) = floor( a(n-1)^2/a(n-2) + 1/2 ).

%H Chai Wah Wu, <a href="/A274951/b274951.txt">Table of n, a(n) for n = 0..1000</a>

%p f:=proc(n, x, y, r) option remember;

%p if n=0 then x

%p elif n=1 then y

%p else floor(f(n-1, x, y, r)^2/f(n-2, x, y, r) + r); fi; end;

%p [seq(f(n, 8, 12, 1/2), n=0..60)];

%o (Python)

%o a, b = 8, 12

%o A274951_list = [a, b]

%o for i in range(1000):

%o c, d = divmod(b**2, a)

%o a, b = b, c + (0 if 2*d < a else 1)

%o A274951_list.append(b) # _Chai Wah Wu_, Aug 06 2016

%Y Cf. A008776, A010916.

%K nonn

%O 0,1

%A _N. J. A. Sloane_, Aug 05 2016

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 September 15 12:32 EDT 2024. Contains 375938 sequences. (Running on oeis4.)