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!)
A097450 If n is square, replace with the sqrt(n)-th prime. 0
2, 2, 3, 3, 5, 6, 7, 8, 5, 10, 11, 12, 13, 14, 15, 7, 17, 18, 19, 20, 21, 22, 23, 24, 11, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 13, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 17, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 19, 65, 66, 67, 68, 69, 70, 71, 72, 73 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
sqrt(16) = 4. replace 16 with prime(4) = 7.
MATHEMATICA
snp[n_]:=Module[{s=Sqrt[n]}, If[IntegerQ[s], Prime[s], n]]; Array[snp, 80] (* Harvey P. Dale, Jun 21 2013 *)
PROG
(PARI) replsqpx(n) = { for(x=1, n, if(issquare(x), y=prime(floor(sqrt(x))), y=x); print1(floor(y)", ")) }
CROSSREFS
Sequence in context: A325852 A332668 A206439 * A062303 A180682 A227426
KEYWORD
nonn
AUTHOR
Cino Hilliard, Aug 23 2004
STATUS
approved

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 May 28 18:29 EDT 2023. Contains 363019 sequences. (Running on oeis4.)