# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a101000 Showing 1-1 of 1 %I A101000 #33 Oct 09 2024 15:36:16 %S A101000 0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0, %T A101000 1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1, %U A101000 3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3,0,1,3 %N A101000 Period 3: repeat [0, 1, 3]. %H A101000 Index entries for linear recurrences with constant coefficients, signature (0,0,1). %F A101000 a(n) = floor((n mod 3)*3/2). - _Reinhard Zumkeller_, Jun 23 2007 %F A101000 a(n) = 4 - a(n-1) - a(n-2) for n > 1. - _Reinhard Zumkeller_, Apr 13 2008 %F A101000 G.f.: x*(1+3*x)/(1-x^3). - _Jaume Oliver Lafont_, Mar 24 2009 %F A101000 a(n) = 2^(n mod 3) - 1. - _Wesley Ivan Hurt_, Apr 16 2014 %F A101000 a(n) = (7*a(n-1) + 2)*(3 - a(n-1))/6 for n > 0. - _Nicolas Bělohoubek_, Oct 09 2024 %p A101000 A101000:=n->2^(n mod 3) - 1; seq(A101000(n), n=0..100); # _Wesley Ivan Hurt_, Apr 16 2014 %t A101000 PadRight[{},120,{0,1,3}] (* _Harvey P. Dale_, Apr 28 2012 *) %t A101000 Table[2^Mod[n, 3] - 1, {n, 0, 100}] (* _Wesley Ivan Hurt_, Apr 16 2014 *) %o A101000 (PARI) a(n)=n%3+(n%3==2) \\ _Jaume Oliver Lafont_, Mar 24 2009 %o A101000 (PARI) a(n)=2^(n%3)-1 \\ _Jaume Oliver Lafont_, Mar 24 2009 %K A101000 nonn,easy %O A101000 0,3 %A A101000 _N. J. A. Sloane_, Jun 17 2007 # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE