The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A247617 a(4n) = n + 1/2 - (-1)^n/2 + (-1)^n, a(2n+1) = 2*n + 5, a(4n+2) = 2*n + 3. 2
1, 5, 3, 7, 1, 9, 5, 11, 3, 13, 7, 15, 3, 17, 9, 19, 5, 21, 11, 23, 5, 25, 13, 27, 7, 29, 15, 31, 7, 33, 17, 35, 9, 37, 19, 39, 9, 41, 21, 43, 11, 45, 23, 47, 11, 49, 25, 51, 13, 53, 27, 55, 13, 57, 29, 59, 15, 61, 31, 63, 15, 65, 33, 67 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
COMMENTS
Essentially a permutation of A129756 (odd numbers repeated four times).
a(-1) = 3, a(-2) = a(-3) = 1.
Distance between the first two (2*k+1)'s: 2*k+1 terms. Distance between the last two (2*n+1)'s: 4 terms. Essentially same distances as in -a(-n) = -1, -3, -1, -1, 1, 1, 1, 3, 1, 5, 3, 7, 3, 9, 5, 11, 3, 13, 7, 15, 5, 17, 9, 19, 5, 21, 11, 23, 7, 25, 13, 27, 7, ... .
LINKS
FORMULA
a(n) = a(n-4) + a(n-8) - a(n-12).
a(n) * A246416(n) = A061037(n+2).
A246416(n+4) - a(n) = sequence of period 4: [1, 0, 0, 0].
a(n+4) - a(n) = sequence of period 8: [0, 4, 2, 4, 2, 4, 2, 4].
G.f.: -(3*x^11+x^10+x^9-x^8-4*x^7-2*x^6-4*x^5-7*x^3-3*x^2-5*x-1) / ((x-1)^2*(x+1)^2*(x^2+1)^2*(x^4+1)). - Colin Barker, Sep 21 2014
a(n) = a(n-8) + sequence of period 4: [2, 8, 4, 8] (= 2*A176895(n)).
a(-n) * A246416(-n) = A061037(n-2).
a(n) = (n+4)*(1-ceiling((2-n)/4)-ceiling((n-2)/4))/2+(n+4)*(1+floor((1-n)/2)+floor((n-1)/2))-(n+2+2(-1)^(n/4))*(ceiling(n/4)-floor(n/4)-1)/4. - Wesley Ivan Hurt, Sep 21 2014
MAPLE
A247617:=n->(n+4)*(1-ceil((2-n)/4)-ceil((n-2)/4))/2+(n+4)*(1+floor((1-n)/2)+floor((n-1)/2))-(n+2+2*(-1)^(n/4))*(ceil(n/4)-floor(n/4)-1)/4: seq(A247617(n), n=0..50); # Wesley Ivan Hurt, Sep 21 2014
MATHEMATICA
Table[(n + 4) (1 - Ceiling[(2 - n)/4] - Ceiling[(n - 2)/4])/2 + (n + 4) (1 + Floor[(1 - n)/2] + Floor[(n - 1)/2]) - (n + 2 + 2 (-1)^(n/4)) (Ceiling[n/4] - Floor[n/4] - 1)/4, {n, 0, 50}] (* Wesley Ivan Hurt, Sep 21 2014 *)
PROG
(PARI) Vec(-(3*x^11+x^10+x^9-x^8-4*x^7-2*x^6-4*x^5-7*x^3-3*x^2-5*x-1)/((x-1)^2*(x+1)^2*(x^2+1)^2*(x^4+1)) + O(x^100)) \\ Colin Barker, Sep 21 2014
(Magma) I:=[1, 5, 3, 7, 1, 9, 5, 11, 3, 13, 7, 15]; [n le 12 select I[n] else Self(n-4)+Self(n-8)-Self(n-12): n in [1..80]]; // Vincenzo Librandi, Oct 15 2014
CROSSREFS
Sequence in context: A338294 A066253 A065169 * A099217 A023103 A153454
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, Sep 21 2014
STATUS
approved

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 June 7 16:36 EDT 2024. Contains 373202 sequences. (Running on oeis4.)