login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A261865 a(n) is the least integer k such that some multiple of sqrt(k) falls strictly between n and n+1. 7
2, 2, 3, 2, 2, 3, 2, 2, 2, 3, 2, 2, 3, 2, 2, 2, 3, 2, 2, 3, 2, 2, 7, 2, 2, 2, 3, 2, 2, 15, 2, 2, 2, 3, 2, 2, 7, 2, 2, 5, 2, 2, 2, 5, 2, 2, 7, 2, 2, 2, 3, 2, 2, 13, 2, 2, 2, 3, 2, 2, 6, 2, 2, 3, 2, 2, 2, 6, 2, 2, 3, 2, 2, 2, 6, 2, 2, 5, 2, 2, 3, 2, 2, 2, 6, 2 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

a(n) is squarefree for all n.

Record values occur at a(1)=2, a(3)=3, a(23)=7, a(30)=15, a(184)=38, a(8091)=43, a(16060)=46, a(16907)=58, a(20993)=61, a(26286)=97, a(130375)=118, a(169819)=127, a(2135662)=130, a(2345213)=187, a(222125822)=210, a(257240414)=227, ... - Jon E. Schoenfield, Sep 07 2015

a(n) > 2 iff n is in A001952. - Robert Israel, Aug 18 2016

LINKS

Peter Kagey, Table of n, a(n) for n = 1..10000

EXAMPLE

a(40) = 5 because:

40 * sqrt(1) = 40 and 41 * sqrt(1) = 41

28 * sqrt(2) < 40 and 29 * sqrt(2) > 41

23 * sqrt(3) < 40 and 24 * sqrt(3) > 41

20 * sqrt(4) = 40 and 21 * sqrt(4) > 41

40 < 18 * sqrt(5) < 41

Thus sqrt(5) is the least integer root with integer multiple between 40 and 41.

MAPLE

f:= proc(n) local k;

  for k from 2 do

     if ceil(sqrt((n+1)^2/k)) - floor(sqrt(n^2/k)) >= 2 then return k fi

  od

end proc:

map(f, [$1..100]); # Robert Israel, Aug 18 2016

MATHEMATICA

Table[k = 2; While[Ceiling[Sqrt[(n + 1)^2/k]] - Floor[Sqrt[n^2/k]] < 2, k++]; k, {n, 120}] (* Michael De Vlieger, Aug 18 2016, after Maple *)

PROG

(Ruby) def a(n); (1..n**2+1).find { |k| (n/k**0.5+1).to_i*k**0.5 < n+1 } end

(PARI) ok(n, k)=h = floor((n+1)/sqrt(k)); (n < h*sqrt(k)) && (h*sqrt(k)< (n+1));

a(n) = my(k=1); while (!ok(n, k), k++); k; \\ Michel Marcus, Sep 04 2015

CROSSREFS

Cf. A001952, A005117, A262036, A273620.

Sequence in context: A107259 A121041 A157439 * A003589 A082204 A152727

Adjacent sequences:  A261862 A261863 A261864 * A261866 A261867 A261868

KEYWORD

nonn

AUTHOR

Peter Kagey, Sep 03 2015

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 21 06:24 EDT 2021. Contains 345358 sequences. (Running on oeis4.)