Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
A021823
Decimal expansion of 1/819.
14
0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1
OFFSET
0,4
COMMENTS
Partial sums of A010892. - Paul Barry, Jun 06 2003
Expansion in any base b >= 3 of 1/((b-1)*(b^2-b+1)) = 1/(b^3-2b^2+2b-1). E.g., 1/14 in base 3, 1/39 in base 4, 1/84 in base 5, etc. - Franklin T. Adams-Watters, Nov 07 2006
a(n) is the second least significant digit in the ternary representation of 2^n (cf. A004642). - Alexandre Herrera, Oct 09 2023
FORMULA
a(n) = a(n-1)-a(n-2)+1 = 2-a(n-3) = a(n-6). - Henry Bottomley, Apr 12 2000
a(n) = Sum_{k=1..floor(n/2)} (-1)^(k+1)*binomial(n-k, k) = 1-((-1)^floor(n/3)+(-1)^(floor((n+1)/3)))/2. - Vladeta Jovovic, Feb 10 2003
G.f.: x^2/(1-2x+2x^2-x^3)=x^2/((1-x)(x^2-x+1)). - Paul Barry, Jun 06 2003
a(n+2) = sum{k=0..n, binomial(n-2k, n-k)}. - Paul Barry, Jan 15 2005
a(0)=0, a(1)=0, a(2)=1, a(n)=2*a(n-1)-2*a(n-2)+a(n-3). - Harvey P. Dale, Aug 19 2012
EXAMPLE
0.0012210012210012210...
MATHEMATICA
Join[{0, 0}, RealDigits[1/819, 10, 120][[1]]] (* or *) PadRight[{}, 120, {0, 0, 1, 2, 2, 1}] (* or *) LinearRecurrence[{2, -2, 1}, {0, 0, 1}, 120] (* Harvey P. Dale, Aug 19 2012 *)
PROG
(PARI) a(n)=1/819. \\ Charles R Greathouse IV, Sep 24 2015
CROSSREFS
Cf. A004642, A153130 (2^n mod 9).
Sequence in context: A281497 A198243 A164965 * A131026 A333839 A014604
KEYWORD
nonn,cons,easy
STATUS
approved