OFFSET
2,1
COMMENTS
For a guide to related sequences, see A001000. - Clark Kimberling, Aug 12 2012
From Jianing Song, Aug 31 2022: (Start)
Smallest m such that ceiling(m/(2*j)) - floor(m/(2*j+2)) >= 5 for 1 <= j <= n-1.
Obviously we have a(n) > 3/(1/(2*n-2) - 1/(2*n)) = 6*n*(n-1). On the other hand, a(n) <= 4/(1/(2*n-2) - 1/(2*n)) + 1 = 8*n*(n-1) + 1: if m >= 8*n*(n-1) + 1, then m/(2*j) - m/(2*j+2) > 4 => ceiling(m/(2*j)) - floor(m/(2*j+2)) = ceiling(m/(2*j)-floor(m/(2*j+2))) >= ceiling(m/(2*j) - m/(2*j+2)) >= 5 for 1 <= j <= n-1.
a(n) is odd for all n: for even m, we have ceiling(m/(2*j)) = ceiling((m-1)/(2*j)) (otherwise (m-1)/(2*j) would be an integer, which is impossible), so ceiling(m/(2*j)) - floor(m/(2*j+2)) >= 5 implies ceiling((m-1)/(2*j)) - floor((m-1)/(2*j+2)) >= 5. (End)
LINKS
Clark Kimberling, Table of n, a(n) for n = 2..100
MATHEMATICA
leastSeparatorS[seq_, s_] := Module[{n = 1},
Table[While[Or @@ (Ceiling[n #1[[1]]] <
s + 1 + Floor[n #1[[2]]] &) /@ (Sort[#1, Greater] &) /@
Partition[Take[seq, k], 2, 1], n++]; n, {k, 2, Length[seq]}]];
t = Map[leastSeparatorS[1/(2*Range[50]), #] &, Range[5]];
t[[4]] (* A024845 *)
(* Peter J. C. Moses, Aug 06 2012 *)
PROG
(PARI) a(n) = for(m=6*n^2-6*n+1, 8*n^2-8*n+1, forstep(j=n-1, 1, -1, if(-((-m)\(2*j)) - m\(2*j+2) < 5, break(), if(j==1, return(m))))) \\ Jianing Song, Aug 31 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved