|
|
A008619
|
|
Positive integers repeated.
|
|
230
|
|
|
1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 14, 14, 15, 15, 16, 16, 17, 17, 18, 18, 19, 19, 20, 20, 21, 21, 22, 22, 23, 23, 24, 24, 25, 25, 26, 26, 27, 27, 28, 28, 29, 29, 30, 30, 31, 31, 32, 32, 33, 33, 34, 34, 35, 35, 36, 36, 37, 37, 38
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
The floor of the arithmetic mean of the first n+1 positive integers. - Cino Hilliard, Sep 06 2003
Number of partitions of n into powers of 2 where no power is used more than three times, or 4th binary partition function (see A072170).
Number of partitions of n in which the greatest part is at most 2. - Robert G. Wilson v, Jan 11 2002
Number of partitions of n into at most 2 parts. - Jon Perry, Jun 16 2003
a(n) = #{k=0..n: k+n is even}. - Paul Barry, Sep 13 2003
Number of symmetric Dyck paths of semilength n+2 and having two peaks. E.g., a(6)=4 because we have UUUUUUU*DU*DDDDDDD, UUUUUU*DDUU*DDDDDD, UUUUU*DDDUUU*DDDDD and UUUU*DDDDUUUU*DDDD, where U=(1,1), D=(1,-1) and * indicates a peak. - Emeric Deutsch, Jan 12 2004
Smallest positive integer whose harmonic mean with another positive integer is n (for n > 0). For example, a(6)=4 is already given (as 4 is the smallest positive integer such that the harmonic mean of 4 (with 12) is 6) - but the harmonic mean of 2 (with -6) is also 6 and 2 < 4, so the two positive integer restrictions need to be imposed to rule out both 2 and -6.
Coefficient of q^n in the expansion of (m choose 2)_q as m goes to infinity. - Y. Kelly Itakura (yitkr(AT)mta.ca), Aug 21 2002
This Itakura comment follows from a partial fraction decomposition (m choose 2)_q = [(1-q^(2m-2))/(1+q) + (1-q^(2m-2))/(1-q) +2 (1-q^(m-1))^2/(1-q)^2]/4. Interpreted as generating functions in q, they have convolution structures; the first term in the numerator creates +1,-1,+1,-1 etc, the 2nd term creates +1,+1,+1,+1 etc., the 3rd term 2,4,6,8, etc. as m->infinity. - R. J. Mathar, Sep 25 2008
From Jon Perry_, Nov 16 2010: (Start)
Column sums of:
1 1 1 1 1 1...
1 1 1 1...
1 1...
..............
--------------
1 1 2 2 3 3... (End)
This sequence is also the half-convolution of the powers of 1 sequence A000012 with itself. For the definition of half-convolution see a comment on A201204, where also the rule for the o.g.f. is given. - Wolfdieter Lang, Jan 09 2012
a(n) is also the number of roots of the n-th Bernoulli polynomial in the right half-plane for n>0. - Michel Lagneau, Nov 08 2012
a(n) is the number of symmetry-allowed, linearly-independent terms at n-th order in the series expansion of the Exe vibronic perturbation matrix, H(Q) (cf. Viel & Eisfeld). - Bradley Klee, Jul 21 2015
a(n) is the number of distinct integers in the n-th row of Pascal's triangle. - Melvin Peralta, Feb 03 2016
a(n+1) for n >= 3 is the diameter of the Generalized Petersen Graph G(n, 1). - Nick Mayers, Jun 06 2016
Also, this sequence is the second column in the triangle of the coefficients of the sum of two consecutive Fibonacci polynomials F(n+1, x) and F(n, x) (n>=0) in ascending powers of x. - Mohammad K. Azarian, Jul 18 2018
a(n+2) is the least k such that given any k integers, there exist two of them whose sum or difference is divisible by n. - Pablo Hueso Merino, May 09 2020
|
|
REFERENCES
|
D. J. Benson, Polynomial Invariants of Finite Groups, Cambridge, 1993, p. 100.
L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 109, Eq. [6c]; p. 116, P(n,2).
D. Parisse, 'The tower of Hanoi and the Stern-Brocot Array', Thesis, Munich 1997
|
|
LINKS
|
Bruce Reznick, Some binary partition functions, in "Analytic number theory" (Conf. in honor P. T. Bateman, Allerton Park, IL, 1989), 451-477, Progr. Math., 85, Birkhäuser Boston, Boston, MA, 1990.
|
|
FORMULA
|
Euler transform of [1, 1].
a(n) = 1 + floor(n/2).
G.f.: 1/((1-x)(1-x^2)).
E.g.f.: ((3+2*x)*exp(x) + exp(-x))/4.
a(n) = a(n-1) + a(n-2) - a(n-3) = -a(-3-n).
a(0) = a(1) = 1 and a(n) = floor( (a(n-1) + a(n-2))/2 + 1 ).
a(n) = (2*n + 3 + (-1)^n)/4. - Paul Barry, May 27 2003
a(n) = Sum_{k=0..n} Sum_{j=0..k} Sum_{i=0..j} binomial(j, i)*(-2)^i. - Paul Barry, Aug 26 2003
E.g.f.: ((1+x)*exp(x) + cosh(x))/2. - Paul Barry, Sep 13 2003
INVERT transformation yields A006054 without leading zeros. INVERTi transformation yields negative of A124745 with the first 5 terms there dropped. - R. J. Mathar, Sep 11 2008
a(n) = n*a(n-1) mod (n+1) = -a(n-1) mod (n+1), the least positive residue modulo n+1 for each expression for n > 0, with a(0) = 1 (basically restatements of Vincenzo Librandi's formula). - Rick L. Shepherd, Apr 02 2014
a(n) = (a(0) + a(1) + ... + a(n-1))/a(n-1), where a(0) = 1. - Melvin Peralta, Jun 16 2015
|
|
MAPLE
|
a:= n-> iquo(n+2, 2): seq(a(n), n=0..75);
|
|
MATHEMATICA
|
CoefficientList[Series[1/(1 - x - x^2 + x^3), {x, 0, 75}], x] (* Robert G. Wilson v, Feb 05 2015 *)
Table[QBinomial[n, 2, -1], {n, 2, 75}] (* John Keith, Jun 28 2021 *)
|
|
PROG
|
(PARI) a(n)=n\2+1
(Haskell)
a008619 = (+ 1) . (`div` 2)
a008619_list = concatMap (\x -> [x, x]) [1..]
(Sage)
a = lambda n: 1 if n==0 else a(n-1)+1 if 2.divides(n) else a(n-1) # Peter Luschny, Feb 05 2015
(Magma) I:=[1, 1, 2]; [n le 3 select I[n] else Self(n-1)+Self(n-2)-Self(n-3): n in [1..100]]; // Vincenzo Librandi, Feb 04 2015
(Python)
|
|
CROSSREFS
|
Harmonic mean of a(n) and A056136 is n.
|
|
KEYWORD
|
nonn,easy,nice
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|