This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A011369 #52 Nov 08 2024 10:28:40 %S A011369 0,0,1,2,4,1,6,14,1,22,56,1,90,234,1,378,988,1,1598,4182,1,6766,17712, %T A011369 1,28658,75026,1,121394,317812,1,514230,1346270,1,2178310,5702888,1, %U A011369 9227466,24157818,1,39088170,102334156,1,165580142,433494438,1,701408734,1836311904 %N A011369 a(n+1) = a(n) - F(n) if > 0, otherwise a(n) + F(n), where F() are Fibonacci numbers; a(0) = 0. %H A011369 Seiichi Manyama, <a href="/A011369/b011369.txt">Table of n, a(n) for n = 0..4000</a> %H A011369 <a href="/index/Rec#order_07">Index entries for linear recurrences with constant coefficients</a>, signature (1,0,4,-4,0,1,-1). %F A011369 a(n) = 0, if n <= 1; F(n-1)+1, if n == 0 (mod 3); F(n)+1, if n == 1 (mod 3); 1, if n == 2 (mod 3). - _David W. Wilson_; corrected by _Michel Marcus_, Dec 29 2018 %F A011369 For n>=1, a(n) = F(0)<+>F(1)<+>...<+>F(n-1), where operation <+> is defined in comment in A245618. - _Vladimir Shevelev_, Nov 05 2014 %F A011369 Empirical g.f.: -x^2*(2*x^6 - x^4 + 7*x^3 - 2*x^2 - x - 1) / ((x-1)*(x^2 + x - 1)*(x^4 - x^3 + 2*x^2 + x + 1)). - _Colin Barker_, Nov 06 2014 %t A011369 Module[{n = 0, f}, NestList[If[(f = Fibonacci[n++]) < #, # - f, # + f] &, 0, 49]] (* _Paolo Xausa_, Nov 08 2024 *) %t A011369 Flatten[Join[{0, 0}, Table[{1, Fibonacci[{k, k+2}] + 1}, {k, 2, 49, 3}]]] (* _Paolo Xausa_, Nov 08 2024 *) %t A011369 LinearRecurrence[{1, 0, 4, -4, 0, 1, -1}, {0, 0, 1, 2, 4, 1, 6, 14, 1}, 50] (* _Paolo Xausa_, Nov 08 2024 *) %o A011369 (PARI) a(n) = if (n==0, 0, my(d=a(n-1)-fibonacci(n-1)); if (d>0, d, d+2*fibonacci(n-1))) \\ _Michel Marcus_, Dec 29 2018 %o A011369 (PARI) a(n) = if (n<=1, 0, my(m=(n % 3)); if (m==0, fibonacci(n-1)+1, if (m==1, fibonacci(n)+1, 1))); \\ _Michel Marcus_, Dec 29 2018 %Y A011369 Cf. A000045, A001611, A014437. %K A011369 nonn,easy %O A011369 0,4 %A A011369 _N. J. A. Sloane_ %E A011369 Name edited by _Michel Marcus_, Dec 29 2018