A090772 Numbers that are congruent to {2, 8} mod 10.
2, 8, 12, 18, 22, 28, 32, 38, 42, 48, 52, 58, 62, 68, 72, 78, 82, 88, 92, 98, 102, 108, 112, 118, 122, 128, 132, 138, 142, 148, 152, 158, 162, 168, 172, 178, 182, 188, 192, 198, 202, 208, 212, 218, 222, 228, 232, 238, 242, 248, 252, 258, 262, 268, 272, 278, 282
Offset: 1
Links
- G. C. Greubel, Table of n, a(n) for n = 1..5000
- Index entries for linear recurrences with constant coefficients, signature (1,1,-1).
Programs
-
Magma
m:=50; R
:=PowerSeriesRing(Integers(), m); Coefficients(R!(2*x*(1+3*x+x^2)/((1+x)*(1-x)^2))); // G. C. Greubel, Aug 08 2018 -
Mathematica
Union@ Flatten@ Outer[Plus, {2, 8}, 10 Range[0, 28]] (* or *) CoefficientList[Series[2 (1 + 3x + x^2)/((1 + x) (1 - x)^2), {x, 0, 57}], x] (* Michael De Vlieger, Aug 02 2018 *) LinearRecurrence[{1, 1, -1}, {2, 8, 12}, 61] (* Robert G. Wilson v, Aug 08 2018 *)
-
PARI
is(n) = #setintersect([2, 8], [n%10]) > 0 \\ Felix Fröhlich, Aug 02 2018
-
PARI
Vec(2*x*(1+3*x+x^2)/((1+x)*(1-x)^2) + O(x^60)) \\ Felix Fröhlich, Aug 02 2018
Formula
a(n) = 2 * A047209(n).
a(n) = 10*n - a(n-1) - 10 (with a(1)=2). - Vincenzo Librandi, Nov 16 2010
G.f.: 2*x*(1+3*x+x^2)/((1+x)*(1-x)^2). - Bruno Berselli, Sep 08 2011
a(1) = 2. For n > 1, a(n) = a(n-1) + A226294(n). - Felix Fröhlich, Aug 02 2018
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(1+2/sqrt(5))*Pi/10. - Amiram Eldar, Dec 28 2021
E.g.f.: 2 + ((10*x - 5)*exp(x) + exp(-x))/2. - David Lovler, Sep 03 2022
From Amiram Eldar, Nov 23 2024: (Start)
Product_{n>=1} (1 - (-1)^n/a(n)) = tan(3*Pi/10) (A019952).
Product_{n>=1} (1 + (-1)^n/a(n)) = cosec(2*Pi/5)/2 (= A179290 / 2). (End)
Extensions
Edited and extended by Ray Chandler, Feb 10 2004
Comments