login
A197652
Numbers that are congruent to 0 or 1 mod 10.
6
0, 1, 10, 11, 20, 21, 30, 31, 40, 41, 50, 51, 60, 61, 70, 71, 80, 81, 90, 91, 100, 101, 110, 111, 120, 121, 130, 131, 140, 141, 150, 151, 160, 161, 170, 171, 180, 181, 190, 191, 200, 201, 210, 211, 220, 221, 230, 231, 240, 241, 250, 251, 260, 261, 270, 271
OFFSET
1,3
COMMENTS
From Wesley Ivan Hurt, Sep 26 2015: (Start)
Numbers with last digit 0 or 1.
Complement of (A260181 Union A262389). (End)
Numbers k such that floor(k/2) = 5*floor(k/10). - Bruno Berselli, Oct 05 2017
FORMULA
a(n) = Sum_{k>=0} A030308(n,k)*b(k) with b(0)=1 and b(k) = 5*2^k = A020714(k) for k>0.
From Zak Seidov, Oct 20 2011: (Start)
a(n) = a(n-2) + 10.
a(n) = 5*n - 7 - 2*(-1)^n. (End)
From Vincenzo Librandi, Jul 11 2012: (Start)
G.f.: x^2*(1+9*x)/((1+x)*(1-x)^2).
a(n) = a(n-1) + a(n-2) - a(n-3) for n>3. (End)
E.g.f.: 9 + (5*x - 7)*exp(x) - 2*exp(-x). - David Lovler, Sep 03 2022
MAPLE
A197652:=n->5*n-7-2*(-1)^n: seq(A197652(n), n=1..100); # Wesley Ivan Hurt, Sep 26 2015
MATHEMATICA
CoefficientList[Series[x*(1+9*x)/((1+x)*(1-x)^2), {x, 0, 50}], x] (* Vincenzo Librandi, Jul 11 2012 *)
PROG
(PARI) a(n)=n\2*10+n%2*9-9 \\ Charles R Greathouse IV, Oct 25 2011
(Magma) [5*n-7-2*(-1)^n: n in [1..60]]; // Vincenzo Librandi, Jul 11 2012
(Python)
def A197652(n): return 5*n-(5 if n&1 else 9) # Chai Wah Wu, Oct 29 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Philippe Deléham, Oct 16 2011
STATUS
approved