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

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A257844 a(n) = floor(n/4) * (n mod 4). 9
 0, 0, 0, 0, 0, 1, 2, 3, 0, 2, 4, 6, 0, 3, 6, 9, 0, 4, 8, 12, 0, 5, 10, 15, 0, 6, 12, 18, 0, 7, 14, 21, 0, 8, 16, 24, 0, 9, 18, 27, 0, 10, 20, 30, 0, 11, 22, 33, 0, 12, 24, 36, 0, 13, 26, 39, 0, 14, 28, 42, 0, 15, 30, 45, 0, 16, 32, 48, 0, 17, 34, 51, 0, 18, 36 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,7 COMMENTS Equivalently, write n in base 4, multiply the last digit by the number with its last digit removed. LINKS Colin Barker, Table of n, a(n) for n = 0..1000 Index entries for linear recurrences with constant coefficients, signature (0,0,0,2,0,0,0,-1). FORMULA a(n) = 2*a(n-4)-a(n-8), n>8. - Colin Barker, May 11 2015 G.f.: x^5*(3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2+1)^2). - Colin Barker, May 11 2015 a(n) = (3-2*(-1)^((2*n-1+(-1)^n)/4)-(-1)^n)*(2*n-3+2*(-1)^((2*n-1+(-1)^n)/4)+(-1)^n)/16. - Wesley Ivan Hurt, Jun 22 2015 MAPLE A257844:=n->floor(n/4)*(n mod 4): seq(A257844(n), n=0..100); # Wesley Ivan Hurt, Jun 22 2015 MATHEMATICA Table[Floor[n/4] Mod[n, 4], {n, 0, 100}] (* Wesley Ivan Hurt, Jun 22 2015 *) PROG (PARI) a(n, b=4)=(n=divrem(n, b))[1]*n[2] (PARI) concat([0, 0, 0, 0, 0], Vec(x^5*(3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2+1)^2) + O(x^100))) \\ Colin Barker, May 11 2015 (MAGMA) [Floor(n/4)*(n mod 4) : n in [0..100]]; // Wesley Ivan Hurt, Jun 22 2015 (MAGMA) I:=[0, 0, 0, 0, 0, 1, 2, 3]; [n le 8 select I[n] else 2*Self(n-4)-Self(n-8): n in [1..100]]; // Vincenzo Librandi, Jun 23 2015 CROSSREFS Cf. A142150 (the base 2 analog), A115273, A257845 - A257850. Sequence in context: A267852 A328568 A219864 * A194745 A248342 A002392 Adjacent sequences:  A257841 A257842 A257843 * A257845 A257846 A257847 KEYWORD nonn,base,easy AUTHOR M. F. Hasler, May 10 2015 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.

Last modified April 17 04:36 EDT 2021. Contains 343059 sequences. (Running on oeis4.)