The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A097362 a(n) = (n+1)/2 if n is odd, n+2 otherwise. 4
 1, 4, 2, 6, 3, 8, 4, 10, 5, 12, 6, 14, 7, 16, 8, 18, 9, 20, 10, 22, 11, 24, 12, 26, 13, 28, 14, 30, 15, 32, 16, 34, 17, 36, 18, 38, 19, 40, 20, 42, 21, 44, 22, 46, 23, 48, 24, 50, 25, 52, 26, 54, 27, 56, 28, 58, 29, 60, 30, 62, 31, 64, 32, 66, 33, 68, 34, 70, 35, 72, 36, 74, 37 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 COMMENTS May be regarded as table T(n,j) for j=1 to 2, where T(n,1)=n, T(n,2)=2*n+2 T(n,1)=number of carbon atoms in alkane hydrocarbons C_n H_{2n+2}, T(n,2)=number of hydrogen atoms in alkane hydrocarbons C_nH_{2n+2}. LINKS Arkadiusz Wesolowski, Table of n, a(n) for n = 1..10000 Index entries for linear recurrences with constant coefficients, signature (0,2,0,-1). FORMULA G.f.: (2 + x)/(1 - x^2)^2. - Arkadiusz Wesolowski, Dec 28 2011 MATHEMATICA a[n_] := If[OddQ[n], (n + 1)/2, n + 2]; Table[a[n], {n, 100}] (* Stefan Steinerberger, May 13 2006 *) LinearRecurrence[{0, 2, 0, -1}, {1, 4, 2, 6}, 100] (* Harvey P. Dale, Sep 14 2016 *) PROG (PARI) a(n)=if(n%2, (n+1)/2, n+2) \\ Charles R Greathouse IV, Sep 02 2015 CROSSREFS Cf. A065423. Sequence in context: A247361 A297307 A163238 * A129131 A237056 A285296 Adjacent sequences: A097359 A097360 A097361 * A097363 A097364 A097365 KEYWORD easy,nonn AUTHOR Pierre CAMI, Sep 18 2004 EXTENSIONS More terms from Stefan Steinerberger, May 13 2006 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.

Last modified June 6 05:06 EDT 2023. Contains 363139 sequences. (Running on oeis4.)