%I #58 Aug 04 2024 11:02:35
%S 1,1,4,15,46,125,316,763,1786,4089,9208,20471,45046,98293,212980,
%T 458739,983026,2097137,4456432,9437167,19922926,41943021,88080364,
%U 184549355,385875946,805306345,1677721576,3489660903,7247757286,15032385509,31138512868,64424509411,133143986146,274877906913,566935683040,1168231104479
%N a(n) = n + (n-1)*(2^n-2).
%C Number of elements in the semigroup IDT_n.
%H Vincenzo Librandi, <a href="/A188716/b188716.txt">Table of n, a(n) for n = 0..200</a>
%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (6,-13,12,-4).
%F From _Colin Barker_, Apr 06 2012: (Start)
%F a(n) = 6*a(n-1)-13*a(n-2)+12*a(n-3)-4*a(n-4).
%F G.f.: (1-5*x+11*x^2-8*x^3)/((1-x)^2*(1-2*x)^2). (End)
%F a(n) = A000337(n) - (n-1). - _Andrew Penland_ , Mar 24 2016
%F E.g.f.: exp(x)*(2 - x + exp(x)*(2*x - 1)). - _Stefano Spezia_, Apr 10 2022
%t Table[n+(n-1)(2^n-2),{n,0,40}] (* or *) LinearRecurrence[{6,-13,12,-4},{1,1,4,15},40] (* _Harvey P. Dale_, Aug 03 2024 *)
%o (Magma) [n + (n-1)*(2^n-2): n in [0..50]]; // _Vincenzo Librandi_, May 01 2011
%o (PARI) a(n)=(n-1)<<n-n+2 \\ _Charles R Greathouse IV_, Apr 06 2012
%Y Cf. A000337, A188377, A188947.
%K nonn,easy
%O 0,3
%A _Adeniji, Adenike_ and Samuel Makanjuola (somakanjuola(AT)unilorin.edu.ng) Apr 14 2011
%E Edited by _N. J. A. Sloane_, Apr 23 2011
%E Offset changed from 1 to 0 by _Vincenzo Librandi_, May 01 2011