login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A119518 Abs(*+-) n Sequence. 0
1, 2, 5, 1, 15, 9, 16, 65, 56, 66, 166, 154, 167, 336, 321, 337, 593, 575, 594, 955, 934, 956, 1440, 1416, 1441, 2066, 2039, 2067, 2851, 2821, 2852, 3813, 3780, 3814, 4970, 4934, 4971, 6340, 6301, 6341, 7941, 7899, 7942, 9791, 9746, 9792, 11908, 11860 (list; graph; refs; listen; history; internal format)
OFFSET

1,2

FORMULA

ABS(1+2*3-4+...+(n-2)*(n-1)-n)

a(3*s) = abs[4 + 3*A000217(s) - 2*s - 9*A000217(s - 1) - 9*A000330(s - 1)] = abs[4 + 5s/2 + 3s^2/2 - 3s^3], s = 1, 2, 3... a(3*s - 1) = abs[4 + 3*A000217(s) - 5*s - 9*A000217(s - 1) - 9*A000330(s - 1)] = abs[4 - s/2 + 3s^2/2 - 3s^3], s = 1, 2, 3.. - R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Jan 25 2007

EXAMPLE

a(1)=1

a(2)=1*2

a(3)=1*2+3

a(4)=1*2+3-4

a(5)=1*2+3-4*5

a(6)=1*2+3-4*5+6

a(7)=1*2+3-4*5+6-7

a(8)=1*2+3-4*5+6-7*8

MATHEMATICA

s={1, 2}; b=2; Do[b=b+Switch[Mod[n, 3], 0, Plus[n], 1, -n, 2, -(n-1)^2]; AppendTo[s, Abs[b]], {n, 3, 50}]; s - Zak Seidov (zakseidov(AT)yahoo.com), Jul 30 2006

CROSSREFS

Sequence in context: A178978 A101895 A110220 * A186756 A184940 A111797

Adjacent sequences:  A119515 A119516 A119517 * A119519 A119520 A119521

KEYWORD

nonn

AUTHOR

Jorge Coveiro (jorgecoveiro(AT)yahoo.com), Jul 27 2006

EXTENSIONS

Corrected and extended by Zak Seidov (zakseidov(AT)yahoo.com), Jul 30 2006

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 14 09:35 EST 2012. Contains 205614 sequences.