login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A018903 Define the sequence S(a(0),a(1)) by a(n+2) is the least integer such that a(n+2)/a(n+1) > a(n+1)/a(n) for n >= 0. This is S(1,5). 3
1, 5, 26, 136, 712, 3728, 19520, 102208, 535168, 2802176, 14672384, 76825600, 402264064, 2106281984, 11028635648, 57746685952, 302365573120, 1583206694912, 8289777876992, 43405840482304, 227275931385856, 1190032226385920, 6231089632772096, 32626408891088896 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

COMMENTS

a(n) is the number of compositions of n when there are 5 types of ones. - Milan Janjic, Aug 13 2010

a(n)/a(n-1) tends to (6 + sqrt(20))/2 = 5.236067.... - Gary W. Adamson, Jul 30 2013

Number of words of length n over {0,1,...,6} in which each 1 is followed by at least one zero. - Milan Janjic, Jan 24 2017

LINKS

Colin Barker, 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.

H. D. Nguyen, D. Taggart, Mining the OEIS: Ten Experimental Conjectures, 2013. Mentions this sequence. - From N. J. A. Sloane, Mar 16 2014

INRIA Algorithms Project, Encyclopedia of Combinatorial Structures 879

Index entries for linear recurrences with constant coefficients, signature (6,-4).

FORMULA

a(n) = (a(1)+1)*a(n-1) - (a(1)-1)*a(n-2) = 6*a(n-1) - 4*a(n-2).

G.f.: (1 - x)/(1 - 6*x + 4*x^2). - Colin Barker, Feb 04 2012

a(n) = 2^(n-1)*A000045(2*n+3). - Sergio Falcon, Jan 25 2017

a(n) = ((3-sqrt(5))^n*(-2+sqrt(5)) + (2+sqrt(5))*(3+sqrt(5))^n) / (2*sqrt(5)). - Colin Barker, Jan 20 2017

Equivalent to the first formula: a(n)=a(1)+a(2)+....+a(n-2)+5*a(n-1). - Arie Bos, May 05 2017

a(n) = Sum_{k>=1} binomial(k+n-1,n) * A000045(k) / 2^(k+1). - Diego Rattaggi, Jun 25 2020

MATHEMATICA

LinearRecurrence[{6, -4}, {1, 5}, 24] (* or *)

CoefficientList[Series[(1 - x)/(1 - 6 x + 4 x^2), {x, 0, 23}], x] (* or *)

a = {1, 5}; Do[AppendTo[a, 6 a[[n - 1]] - 4 a[[n - 2]]], {n, 3, 24}];

a (* or *)

S[a_, b_, n_] := Block[{s = {a, b}, k}, Do[k = Last@ s + 1; While[k/s[[i - 1]] <= s[[i - 1]]/s[[i - 2]], k++]; AppendTo[s, k], {i, 3, n}]; s]; S[1, 5, 10] (* Michael De Vlieger, Feb 15 2016 *)

PROG

(PARI) S(a0, a1, maxn) = a=vector(maxn); a[1]=a0; a[2]=a1; for(n=3, maxn, a[n]=a[n-1]^2\a[n-2]+1); a

S(1, 5, 40) \\ Colin Barker, Feb 15 2016

(PARI) Vec((1-x)/(1-6*x+4*x^2) + O(x^40)) \\ Colin Barker, Feb 15 2016

CROSSREFS

Sequence in context: A052918 A255633 A255815 * A083331 A076025 A288785

Adjacent sequences:  A018900 A018901 A018902 * A018904 A018905 A018906

KEYWORD

nonn,easy

AUTHOR

R. K. Guy

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 16 05:26 EDT 2021. Contains 343030 sequences. (Running on oeis4.)