A004119 a(0) = 1; thereafter a(n) = 3*2^(n-1) + 1.
1, 4, 7, 13, 25, 49, 97, 193, 385, 769, 1537, 3073, 6145, 12289, 24577, 49153, 98305, 196609, 393217, 786433, 1572865, 3145729, 6291457, 12582913, 25165825, 50331649, 100663297, 201326593, 402653185, 805306369, 1610612737, 3221225473, 6442450945, 12884901889
Offset: 0
References
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- D. W. Boyd, Linear recurrence relations for some generalized Pisot sequences, Advances in Number Theory ( Kingston ON, 1991) 333-340, Oxford Sci. Publ., Oxford Univ. Press, New York, 1993
- S. W. Golomb, Properties of the sequence 3.2^n+1, Math. Comp., 30 (1976), 657-663.
- S. W. Golomb, Properties of the sequence 3.2^n+1, Math. Comp., 30 (1976), 657-663. [Annotated scanned copy]
- A. O. Munagi and T. Shonhiwa, On the partitions of a number into arithmetic progressions, J. Integer Sequences, 11 (2008), #08.5.4.
- Simon Plouffe, Approximations de séries génératrices et quelques conjectures, Dissertation, Université du Québec à Montréal, 1992; arXiv:0911.4975 [math.NT], 2009.
- Simon Plouffe, 1031 Generating Functions, Appendix to Thesis, Montreal, 1992
- Index entries for linear recurrences with constant coefficients, signature (3, -2).
- Index entries for Pisot sequences
Crossrefs
Programs
-
Magma
[1] cat [n le 1 select 4 else 2*Self(n-1)-1: n in [1..40]]; // Vincenzo Librandi, Dec 16 2015
-
Maple
A004119:=-(-1-z+3*z**2)/(2*z-1)/(z-1); # Simon Plouffe in his 1992 dissertation
-
Mathematica
s=4;lst={1,s};Do[s=s+(s-1);AppendTo[lst,s],{n,5!}];lst (* Vladimir Joseph Stephan Orlovsky, Nov 30 2009 *) Prepend[Table[3*2^n + 1, {n, 0, 32}], 1] (* or *) {1}~Join~LinearRecurrence[{3, -2}, {4, 7}, 33] (* Michael De Vlieger, Dec 16 2015 *)
-
PARI
a(n)=3<
Charles R Greathouse IV, Sep 28 2015
Formula
a(n) = 3a(n-1) - 2a(n-2).
For n>3, a(3)=13, a(n)= a(n-1)+2*floor(a(n-1)/2). - Benoit Cloitre, Aug 14 2002
For n>=1, a(n) = A049775(n+1)/2^(n-2). For n>=2, a(n) = 2a(n-1)-1; see also A000051. - Philippe Deléham, Feb 20 2004
O.g.f.: -(-1-x+3*x^2)/((2*x-1)*(x-1)). - R. J. Mathar, Nov 23 2007
For n>0, a(n) = 2*a(n-1)-1. - Vincenzo Librandi, Dec 16 2015
E.g.f.: exp(x)*(1 + 3*sinh(x)). - Stefano Spezia, May 06 2023
Extensions
Edited by N. J. A. Sloane, Dec 16 2015 at the suggestion of Bruno Berselli
Comments