login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A057354
a(n) = floor(2*n/5).
23
0, 0, 0, 1, 1, 2, 2, 2, 3, 3, 4, 4, 4, 5, 5, 6, 6, 6, 7, 7, 8, 8, 8, 9, 9, 10, 10, 10, 11, 11, 12, 12, 12, 13, 13, 14, 14, 14, 15, 15, 16, 16, 16, 17, 17, 18, 18, 18, 19, 19, 20, 20, 20, 21, 21, 22, 22, 22, 23, 23, 24, 24, 24, 25, 25, 26, 26, 26, 27, 27, 28, 28, 28, 29, 29, 30, 30
OFFSET
0,6
COMMENTS
The cyclic pattern (and numerator of the gf) is computed using Euclid's algorithm for GCD.
The sequence a(n) can be used in determining confidence intervals for the median of a population. Let Y(i) denote the i-th smallest datum in a random sample of size n from any population of values. When estimating the population median with a symmetric interval [Y(r), Y(n-r+1)], the exact confidence coefficient c for the interval is given by c = Sum_{k=r..n-r} C(n, k)(1/2)^n. If r = a(n-4), then the confidence coefficient will be (i) at least 0.90 for all n>=7, (ii) at least 0.95 for all n>=35, and (iii) at least 0.99 for all n>=115. To use the sequence, for example, decide on the minimum level of confidence desired, say 95%. Hence use a sample size of 35 or greater, say n=40. We then find a(n-4)=a(36)=14, and thus the 14th smallest and 14th largest values in the sample will form the bounds for the confidence interval. If the exact confidence coefficient c is needed, calculate c = Sum_{k=14..26} C(40,k)(1/2)^40, which is 0.9615226917. - Dennis P. Walsh, Nov 28 2011
a(n+2) is also the domination number of the n-antiprism graph. - Eric W. Weisstein, Apr 09 2016
Equals partial sums of 0 together with 0, 0, 1, 0, 1, ... (repeated). - Bruno Berselli, Dec 06 2016
Euler transform of length 5 sequence [1, 1, 0, -1, 1]. - Michael Somos, Dec 06 2016
REFERENCES
N. Dershowitz and E. M. Reingold, Calendrical Calculations, Cambridge University Press, 1997.
R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics, Addison-Wesley, NY, 1994.
LINKS
N. Dershowitz and E. M. Reingold, Calendrical Calculations Web Site.
Eric Weisstein's World of Mathematics, Antiprism Graph.
Eric Weisstein's World of Mathematics, Domination Number.
FORMULA
G.f.: x^3*(1 + x^2) / ((x^4 + x^3 + x^2 + x + 1)*(x - 1)^2). - Numerator corrected by R. J. Mathar, Feb 20 2011
a(n) = a(n-1) + a(n-5) - a(n-6) for n>5. - Colin Barker, Dec 06 2016
a(n) = -a(2-n) for all n in Z. - Michael Somos, Dec 06 2016
a(n) = A002266(2*n). - R. J. Mathar, Jul 21 2020
Sum_{n>=3} (-1)^(n+1)/a(n) = log(2)/2. - Amiram Eldar, Sep 30 2022
EXAMPLE
G.f. = x^3 + x^4 + 2*x^5 + 2*x^6 + 2*x^7 + 3*x^8 + 3*x^9 + 4*x^10 + 4*x^11 + ...
MATHEMATICA
Table[Floor[2 n/5], {n, 0, 80}] (* Bruno Berselli, Dec 06 2016 *)
a[ n_] := Quotient[2 n, 5]; (* Michael Somos, Dec 06 2016 *)
PROG
(PARI) a(n)=2*n\5 \\ Charles R Greathouse IV, Nov 28 2011
(PARI) concat(vector(3), Vec(x^3*(1 + x^2) / ((1 - x)^2*(1 + x + x^2 + x^3 + x^4)) + O(x^80))) \\ Colin Barker, Dec 06 2016.
(Python) [int(2*n/5) for n in range(80)] # Bruno Berselli, Dec 06 2016
(Sage) [floor(2*n/5) for n in range(80)] # Bruno Berselli, Dec 06 2016
(Magma) [2*n div 5: n in [0..80]]; // Bruno Berselli, Dec 06 2016
KEYWORD
nonn,easy
AUTHOR
STATUS
approved