login
a(n) = 2^n + 2*n + 1.
12

%I #46 May 07 2023 05:39:44

%S 2,5,9,15,25,43,77,143,273,531,1045,2071,4121,8219,16413,32799,65569,

%T 131107,262181,524327,1048617,2097195,4194349,8388655,16777265,

%U 33554483,67108917,134217783,268435513,536870971,1073741885,2147483711,4294967361,8589934659,17179869253

%N a(n) = 2^n + 2*n + 1.

%C The subsequence of primes in this sequence is A163115.

%C Also the number of connected dominating sets in the (n+1)-wheel graph. - _Eric W. Weisstein_, Aug 30 2017

%H Seiichi Manyama, <a href="/A176691/b176691.txt">Table of n, a(n) for n = 0..3000</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/ConnectedDominatingSet.html">Connected Dominating Set</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/WheelGraph.html">Wheel Graph</a>

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

%F a(n) = 2^n + 2*n + 1 = A000079(n) + A005843(n) + 1 = A000051(n) + A005843(n).

%F From _R. J. Mathar_, Apr 28 2010: (Start)

%F a(n) = 4*a(n-1) - 5*a(n-2) + 2*a(n-3).

%F G.f.: (-2 + 3*x + x^2)/((2*x - 1)*(x - 1)^2). (End)

%F E.g.f.: exp(x)*(1 + exp(x) + 2*x). - _Stefano Spezia_, May 06 2023

%p seq(2^n+2*n+1,n=0..35); # _Muniru A Asiru_, Mar 25 2018

%t Table[2^n + 2 n + 1, {n, 0, 60}] (* _Vladimir Joseph Stephan Orlovsky_, Feb 15 2011 *)

%t LinearRecurrence[{4, -5, 2}, {2, 5, 9}, 40] (* _Vincenzo Librandi_, Aug 12 2015 *)

%t CoefficientList[Series[(-2 + 3 x + x^2)/((-1 + x)^2 (-1 + 2 x)), {x, 0, 20}], x] (* _Eric W. Weisstein_, Aug 30 2017 *)

%o (PARI) vector(40, n, n--; 2^n + 2*n + 1) \\ _Michel Marcus_, Aug 12 2015

%o (Magma) [2^n + 2*n + 1: n in [0..40]]; // _Vincenzo Librandi_, Aug 12 2015

%o (GAP) List([0..35],n->2^n+2*n+1); # _Muniru A Asiru_, Mar 25 2018

%Y Cf. A000051, A000079, A000290, A005126, A005843, A163115, A194455.

%K nonn,easy

%O 0,1

%A _Jonathan Vos Post_, Apr 23 2010

%E Corrected (one 1048617 replaced by 2097195) by _R. J. Mathar_, Apr 28 2010