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!)
A047438 Numbers that are congruent to {1, 5, 6} mod 8. 2

%I #14 Sep 08 2022 08:44:57

%S 1,5,6,9,13,14,17,21,22,25,29,30,33,37,38,41,45,46,49,53,54,57,61,62,

%T 65,69,70,73,77,78,81,85,86,89,93,94,97,101,102,105,109,110,113,117,

%U 118,121,125,126,129,133,134,137,141,142,145,149,150,153,157,158

%N Numbers that are congruent to {1, 5, 6} mod 8.

%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (1,0,1,-1).

%F G.f.: x*(1+4*x+x^2+2*x^3)/((1+x+x^2)*(x-1)^2). - _R. J. Mathar_, Dec 07 2011

%F From _Wesley Ivan Hurt_, Jun 10 2016: (Start)

%F a(n) = a(n-1) + a(n-3) - a(n-4) for n>4.

%F a(n) = 2*(12*n-6-3*cos(2*n*Pi/3)-2*sqrt(3)*sin(2*n*Pi/3))/9.

%F a(3k) = 8k-2, a(3k-1) = 8k-3, a(3k-2) = 8k-7. (End)

%p A047438:=n->2*(12*n-6-3*cos(2*n*Pi/3)-2*sqrt(3)*sin(2*n*Pi/3))/9: seq(A047438(n), n=1..100); # _Wesley Ivan Hurt_, Jun 10 2016

%t Select[Range[0, 150], MemberQ[{1, 5, 6}, Mod[#, 8]] &] (* _Wesley Ivan Hurt_, Jun 10 2016 *)

%o (Magma) [n : n in [0..150] | n mod 8 in [1, 5, 6]]; // _Wesley Ivan Hurt_, Jun 10 2016

%K nonn,easy

%O 1,2

%A _N. J. A. Sloane_

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 23 07:16 EDT 2024. Contains 371905 sequences. (Running on oeis4.)