login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A130497 Repetition of odd numbers five times. 4

%I

%S 1,1,1,1,1,3,3,3,3,3,5,5,5,5,5,7,7,7,7,7,9,9,9,9,9,11,11,11,11,11,13,

%T 13,13,13,13,15,15,15,15,15,17,17,17,17,17,19,19,19,19,19,21,21,21,21,

%U 21,23,23,23,23,23,25,25,25,25,25,27,27,27,27,27,29,29,29,29,29,31,31,31

%N Repetition of odd numbers five times.

%H G. C. Greubel, <a href="/A130497/b130497.txt">Table of n, a(n) for n = 0..1000</a>

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

%F a(n) = -1 + 2*Sum_{k=0..n} {[8*(sin(2*Pi*k/5))^2-5]^2-5}/20, with n>=0.

%F a(n) = -1 + (1/25)*Sum_{k=0..n} ( (-9*[k mod 5] +[(k+1) mod 5] +[(k+2) mod 5] +[(k+3) mod 5] +11*[(k+4) mod 5]) ), with n>=0.

%F a(n) = -1 + 2*Sum{k=0..n} (1 - (k^4 mod 5) ), with n>=0. - _Paolo P. Lava_, Feb 17 2010

%F From _R. J. Mathar_, Mar 17 2010: (Start)

%F a(n) = a(n-1) + a(n-5) - a(n-6).

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

%F a(n) = 2*floor(n/5)+1 = A130496(n)+1. - _Tani Akinari_, Jul 24 2013

%p P:=proc(n) local i,j,k; for i from 0 by 1 to n do j:=-1+2*sum('(8*(sin(2*Pi*k/5))^2-5)^2-5','k'=0..i)/20 ; print(j); od; end: P(100);

%t Flatten[Table[#,{5}]&/@Range[1,31,2]] (* _Harvey P. Dale_, Mar 27 2013~ *)

%o (PARI) my(x='x+O('x^80)); Vec((1+x^5)/((1-x)*(1-x^5))) \\ _G. C. Greubel_, Sep 12 2019

%o (MAGMA) R<x>:=PowerSeriesRing(Integers(), 80); Coefficients(R!( (1+x^5)/((1-x)*(1-x^5)) )); // _G. C. Greubel_, Sep 12 2019

%o (Sage)

%o def A130497_list(prec):

%o P.<x> = PowerSeriesRing(ZZ, prec)

%o return P((1+x^5)/((1-x)*(1-x^5))).list()

%o A130497_list(80) # _G. C. Greubel_, Sep 12 2019

%o (GAP) a:=[1,1,1,1,1,3];; for n in [7..80] do a[n]:=a[n-1]+a[n-5]-a[n-6]; od; a; # _G. C. Greubel_, Sep 12 2019

%Y Cf. A129756.

%K easy,nonn

%O 0,6

%A _Paolo P. Lava_ and _Giorgio Balzarotti_, May 31 2007

%E Corrected formula by _Paolo P. Lava_, Feb 17 2010

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 17 12:01 EDT 2021. Contains 343971 sequences. (Running on oeis4.)