login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A169986
Ceiling(phi^n) where phi = (1+sqrt(5))/2.
7
1, 2, 3, 5, 7, 12, 18, 30, 47, 77, 123, 200, 322, 522, 843, 1365, 2207, 3572, 5778, 9350, 15127, 24477, 39603, 64080, 103682, 167762, 271443, 439205, 710647, 1149852, 1860498, 3010350, 4870847, 7881197, 12752043, 20633240, 33385282
OFFSET
0,2
FORMULA
For n >= 5, a(n) = a(n-1) + 2a(n-2) - a(n-3) - a(n-4). - Charles R Greathouse IV, Oct 14 2010
a(n) = 3*Fibonacci(n-1) + Fibonacci(n-2) + (n mod 2), n>0. - Gary Detlefs, Dec 29 2010
G.f.: (-x+x^2+x^3+x^4-1) / ((1-x)*(1+x)*(x^2+x-1)). - R. J. Mathar, Jan 06 2011
a(2k) = A000032(2k) = A169985(2k) and a(2k+1) = A000032(2k+1)+1 = A169985(2k+1)+1, for k>0. - Danny Rorabaugh, Apr 15 2015
MATHEMATICA
Ceiling[GoldenRatio^Range[0, 40]] (* or *) Join[{1}, LinearRecurrence[{1, 2, -1, -1}, {2, 3, 5, 7}, 40]] (* Harvey P. Dale, Nov 12 2014 *)
PROG
(Magma) [1] cat [3*Fibonacci(n-1) + Fibonacci(n-2)+ n mod 2: n in [1..40]]; // Vincenzo Librandi, Apr 16 2015
(Sage) [ceil(golden_ratio^n) for n in range(37)] # Danny Rorabaugh, Apr 16 2015
(PARI) a(n)=if(n, 3*fibonacci(n-1) + fibonacci(n-2) + n%2, 1) \\ Charles R Greathouse IV, Apr 16 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Sep 26 2010
STATUS
approved