The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A106706 a(0) = 19; for n>0, successively subtract 5, subtract 3 and double. 1

%I #25 Sep 08 2022 08:45:18

%S 19,14,11,22,17,14,28,23,20,40,35,32,64,59,56,112,107,104,208,203,200,

%T 400,395,392,784,779,776,1552,1547,1544,3088,3083,3080,6160,6155,6152,

%U 12304,12299,12296,24592,24587,24584,49168,49163,49160,98320,98315,98312,196624

%N a(0) = 19; for n>0, successively subtract 5, subtract 3 and double.

%C Suggested by a test found on the Internet.

%H G. C. Greubel, <a href="/A106706/b106706.txt">Table of n, a(n) for n = 0..1000</a>

%H Jeffrey N. Shaumeyer, Bearcastle Blog, <a href="https://web.archive.org/web/20071009070537/http://bearcastle.com/blog/?p=596">One Post, Two ...</a> [Via Internet Archive Wayback-Machine]

%H <a href="/index/Rec#order_06">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,3,0,0,-2).

%F G.f.: (19 + 14*x + 11*x^2 - 35*x^3 - 25*x^4 - 19*x^5)/((1 - 2*x^3)*(1 - x^3)).

%F a(3n) = 3*2^n+16, a(3n+1) = 3*2^n+11, a(3n+2) = 3*2^n+8.

%p f:=proc(n) option remember; if n=0 then RETURN(19); fi; if n mod 3 = 1 then RETURN(f(n-1)-5); elif n mod 3 = 2 then RETURN(f(n-1)-3); else RETURN(2*f(n-1)); fi; end;

%t nxt[{b_,c_,d_}]:={d-5,d-8,2d-16}; Join[{19},Flatten[NestList[nxt,{14,11,22},20]]] (* _Harvey P. Dale_, Dec 01 2019 *)

%o (PARI) a(n)=3*2^(n\3)+[16,11,8][n%3+1] \\ _M. F. Hasler_, Nov 16 2010

%o (Magma) I:=[19,14,11,22,17,14]; [n le 6 select I[n] else 3*Self(n-3) - 2*Self(n-6): n in [1..61]]; // _G. C. Greubel_, Sep 09 2021

%o (Sage)

%o def p(n): return 0 if (n%3==0) else 5 if (n%3==1) else 8

%o def a(n,b): return 2^(n//3)*(b-16) + 16 - p(n)

%o [a(n,19) for n in (0..60)] # _G. C. Greubel_, Sep 09 2021

%K nonn

%O 0,1

%A _N. J. A. Sloane_, based on correspondence with Jeffrey N. Shaumeyer, Apr 23 2006

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 15 04:25 EDT 2024. Contains 372536 sequences. (Running on oeis4.)