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!)
A135440 a(n) = a(n-1) + 2a(n-2). 6

%I #21 Aug 20 2022 13:38:54

%S -1,4,2,10,14,34,62,130,254,514,1022,2050,4094,8194,16382,32770,65534,

%T 131074,262142,524290,1048574,2097154,4194302,8388610,16777214,

%U 33554434,67108862,134217730,268435454,536870914,1073741822,2147483650,4294967294,8589934594,17179869182,34359738370

%N a(n) = a(n-1) + 2a(n-2).

%C First differences of A014551. - _Reinhard Zumkeller_, Jan 02 2013

%C It can be noticed that, once deprived of its first term, this is an "autosequence" of the second kind, whose companion of the first kind is A014113. - _Jean-François Alcover_, Aug 19 2022

%H Reinhard Zumkeller, <a href="/A135440/b135440.txt">Table of n, a(n) for n = 0..1000</a>

%H OEIS Wiki, <a href="https://oeis.org/wiki/Autosequence">Autosequence</a>

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

%F From _R. J. Mathar_, Feb 19 2008: (Start)

%F O.g.f.: -1/(2*x-1) - 2/(1+x).

%F a(n) = 2^n - 2*(-1)^n. (End)

%F a(n) = 2*A014551(n-1), n>0. - _Paul Curtz_, Jun 01 2011

%F E.g.f.: exp(2*x) - 2*exp(-x). - _G. C. Greubel_, Oct 14 2016

%t f[n_]:=2/(n+1);x=4;Table[x=f[x];Numerator[x],{n,0,5!}] (* _Vladimir Joseph Stephan Orlovsky_, Mar 12 2010 *)

%t LinearRecurrence[{1,2}, {-1,4}, 25] (* or *) Table[2^n - 2*(-1)^n, {n,0,25}] (* _G. C. Greubel_, Oct 14 2016 *)

%o (Haskell)

%o a135440 n = a135440_list !! n

%o a135440_list = zipWith (-) (tail a014551_list) a014551_list

%o -- _Reinhard Zumkeller_, Jan 02 2013

%K sign,easy

%O 0,2

%A _Paul Curtz_, Feb 18 2008

%E More terms from _R. J. Mathar_, Feb 19 2008

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 June 29 06:36 EDT 2024. Contains 373826 sequences. (Running on oeis4.)