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

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A230775 Smallest prime number greater than or equal to the square root of n. 2

%I #18 Feb 10 2019 17:57:10

%S 2,2,2,2,3,3,3,3,3,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,7,7,7,7,7,7,7,7,7,

%T 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,11,11,11,11,11,11,11,11,11,11,11,11,11,

%U 11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11

%N Smallest prime number greater than or equal to the square root of n.

%C Or repeat prime(k) (prime(k)^2-prime(k-1)^2) times, with prime(0) set to 0 for k=1.

%H Jean-Christophe Hervé, <a href="/A230775/b230775.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = A000040(A230774(n)).

%F Repeat prime(1) prime(1)^2 times; for k>1, repeat A000040(k) A050216(k-1) times (that is, repeat prime(k) (prime(k)^2 - prime(k-1)^2) times).

%e a(5)=a(6)=a(7)=a(8)=a(9)=3 because prime(1)= 2 < sqrt(5 to 9) <= prime(2) = 3.

%t spn[n_]:=Module[{s=Sqrt[n]},If[PrimeQ[s],s,NextPrime[s]]]; Array[spn,90] (* _Harvey P. Dale_, Feb 10 2019 *)

%Y Cf. A230774, A050216, A056813.

%K nonn,easy

%O 1,1

%A _Jean-Christophe Hervé_, Nov 01 2013

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 15:18 EDT 2024. Contains 371960 sequences. (Running on oeis4.)