login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A257849 a(n) = floor(n/9) * (n mod 9). 2
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 0, 2, 4, 6, 8, 10, 12, 14, 16, 0, 3, 6, 9, 12, 15, 18, 21, 24, 0, 4, 8, 12, 16, 20, 24, 28, 32, 0, 5, 10, 15, 20, 25, 30, 35, 40, 0, 6, 12, 18, 24, 30, 36, 42, 48, 0, 7, 14, 21, 28, 35, 42, 49, 56, 0, 8, 16, 24, 32, 40, 48, 56, 64, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,12
COMMENTS
Equivalently, write n in base 9, multiply the last digit by the number with its last digit removed.
See A142150(n-1) for the base 2 analog, and A115273, A257844 - A257850 for the base 3 - base 10 variants.
LINKS
Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,-1).
FORMULA
a(n) = 2*a(n-9)-a(n-18). - Colin Barker, May 11 2015
G.f.: x^10*(8*x^7+7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x^2+x+1)^2*(x^6+x^3+1)^2). - Colin Barker, May 11 2015
MATHEMATICA
Table[Floor[n/9] Mod[n, 9], {n, 100}] (* Vincenzo Librandi, May 11 2015 *)
PROG
(PARI) A257849(n)=n\9*(n%9)
(Magma) [Floor(n/9)*(n mod 9): n in [0..100]]; // Vincenzo Librandi, May 11 2015
(Sage) [floor(n/9)*(n % 9) for n in (0..80)]; # Bruno Berselli, May 11 2015
(PARI) concat([0, 0, 0, 0, 0, 0, 0, 0, 0, 0], Vec(x^10*(8*x^7+7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x^2+x+1)^2*(x^6+x^3+1)^2) + O(x^100))) \\ Colin Barker, May 11 2015
(Python)
from math import prod
def A257849(n): return prod(divmod(n, 9)) # Chai Wah Wu, Jan 19 2023
CROSSREFS
Cf. A142150 (the base 2 analog), A115273, A257844 - A257850.
Sequence in context: A010878 A309788 A326746 * A190727 A195832 A265523
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 | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 02:27 EDT 2024. Contains 371782 sequences. (Running on oeis4.)