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!)
A047293 Numbers that are congruent to {0, 2, 4, 6} mod 7. 1

%I #27 Sep 08 2022 08:44:56

%S 0,2,4,6,7,9,11,13,14,16,18,20,21,23,25,27,28,30,32,34,35,37,39,41,42,

%T 44,46,48,49,51,53,55,56,58,60,62,63,65,67,69,70,72,74,76,77,79,81,83,

%U 84,86,88,90,91,93,95,97,98,100,102,104,105,107,109,111

%N Numbers that are congruent to {0, 2, 4, 6} mod 7.

%H Vincenzo Librandi, <a href="/A047293/b047293.txt">Table of n, a(n) for n = 1..5000</a>

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

%F a(n) = floor(ceiling((7n + 2)/2)/2).

%F a(n) = 2n-2-floor((n-1)/4). - _Gary Detlefs_, Mar 27 2010

%F From _Colin Barker_, Mar 13 2012: (Start)

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

%F G.f.: x^2*(2+2*x+2*x^2+x^3)/((1-x)^2*(1+x)*(1+x^2)). (End)

%F From _Wesley Ivan Hurt_, May 21 2016: (Start)

%F a(n) = (14n-11+i^(2n)+(1-i)*i^(-n)+(1+i)*i^n)/8 where i=sqrt(-1).

%F a(2n) = A047276(n), a(2n-1) = A047345(n). (End)

%p A047293:=n->2*n-2-floor((n-1)/4): seq(A047293(n), n=1..100); # _Wesley Ivan Hurt_, May 21 2016

%t Select[Range[0,100],MemberQ[{0,2,4,6},Mod[#,7]]&] (* _Vincenzo Librandi_, Apr 26 2012 *)

%t LinearRecurrence[{1,0,0,1,-1},{0,2,4,6,7},80] (* _Harvey P. Dale_, Jun 21 2019 *)

%o (Magma) I:=[0, 2, 4, 6, 7]; [n le 5 select I[n] else Self(n-1)+Self(n-4)-Self(n-5): n in [1..70]]; // _Vincenzo Librandi_, Apr 26 2012

%o (PARI) A047293(n)=n*7\4-1 \\ _M. F. Hasler_, Apr 27 2012

%Y Cf. A047276, A047345.

%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 19 21:09 EDT 2024. Contains 371798 sequences. (Running on oeis4.)