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!)
A338157 Numbers that follow from the alternating series a(n) = d(1) - d(2) + d(3) -d(4) + ... + (-1)^(n+1) d(n), where d(k) denotes the k-th term of the digit sequence of the Golden Ratio. 0

%I #5 Oct 14 2020 10:19:43

%S 1,-5,-4,-12,-12,-15,-12,-21,-13,-21,-14,-18,-9,-17,-8,-12,-4,-8,0,-2,

%T -2,-6,-1,-9,-3,-11,-8,-12,-9,-15,-10,-16,-13,-21,-20,-21,-14,-21,-19,

%U -19,-16,-16,-7,-8,-1,-10,-2,-2,3,-4,2,0,8,2

%N Numbers that follow from the alternating series a(n) = d(1) - d(2) + d(3) -d(4) + ... + (-1)^(n+1) d(n), where d(k) denotes the k-th term of the digit sequence of the Golden Ratio.

%F a(1) = d(1) = 2; a(n) = a(n-1) + (-1)^(n+1) d(n) for n > 1.

%e a(3) = d(1) - d(2) + d(3) = 1 - 6 + 1 = -4.

%t S[X_, n_] :=

%t Accumulate[(-1)^Range[0, n - 1]*RealDigits[X, 10, n][[1]]]

%t S[GoldenRatio, 54] (*This generates the first 54 elements of this sequence*)

%Y Cf. A001622 (Golden Ratio), A069159 (similar sequence for Pi), A338108 (similar sequence for Euler's number).

%K base,easy,sign,less

%O 1,2

%A _Dirk Broeders_, Oct 14 2020

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 July 13 21:13 EDT 2024. Contains 374288 sequences. (Running on oeis4.)