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!)
A103832 For even n, a(n)=2n+1, for odd n, a(n)=n(n+1) 2
1, 2, 5, 12, 9, 30, 13, 56, 17, 90, 21, 132, 25, 182, 29, 240, 33, 306, 37, 380, 41, 462, 45, 552, 49, 650, 53, 756, 57, 870, 61, 992, 65, 1122, 69, 1260, 73, 1406, 77, 1560, 81, 1722, 85, 1892, 89, 2070, 93, 2256, 97, 2450, 101, 2652, 105, 2862, 109, 3080, 113 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
COMMENTS
First the sum then the product of two successive integers.
LINKS
FORMULA
G.f.: (1+3x^2)(1+2x-x^2)/((1-x)^3*(1+x)^3). [R. J. Mathar, Aug 30 2008]
a(n) = (n^2+3*n+1-(n^2-n-1)*(-1)^n)/2. - Luce ETIENNE, Apr 13 2016
E.g.f.: (2*x+1)*cosh(x) + (x^2 + 2*x)*sinh(x). - Ilya Gutkovskiy, Apr 13 2016
a(n) = 3*a(n-2) - 3*a(n-4) + a(n-6). - G. C. Greubel, Apr 13 2016
EXAMPLE
a(4)=4+5=9, a(5)=5*6=30.
MAPLE
seq(2*n+1+(n mod 2)*(n^2-n-1), n=0..100); # Robert Israel, Apr 14 2016
MATHEMATICA
Flatten[Table[{i + i + 1, (i + 1)(i + 2)}, {i, 0, 98, 2}]]
LinearRecurrence[{0, 3, 0, -3, 0, 1}, {1, 2, 5, 12, 9, 30}, 60] (* Harvey P. Dale, Oct 07 2016 *)
PROG
(Python)
for n in range(0, 10**3):
print((int)((n**2+3*n+1-(n**2-n-1)*(-1)**n)/2))
# Soumil Mandal, Apr 14 2016
CROSSREFS
Cf. A103831.
Sequence in context: A110020 A070266 A125199 * A348891 A191368 A085227
KEYWORD
nonn
AUTHOR
Zak Seidov, Feb 17 2005, Feb 18 2005
EXTENSIONS
Edited by N. J. A. Sloane, Aug 29 2008 at the suggestion of R. J. Mathar
Corrected typo in the definition - R. J. Mathar, Sep 07 2010
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 March 28 20:05 EDT 2024. Contains 371254 sequences. (Running on oeis4.)