login
This site is supported by donations to The OEIS Foundation.

 

Logo

Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing.
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A248595 Smallest prime number Q such that there is a prime number R such that floor(Q/R)=prime(n). 3

%I

%S 5,7,11,23,23,41,53,59,47,59,157,113,83,131,239,107,179,307,337,359,

%T 367,239,167,179,293,509,311,751,547,227,383,263,1511,419,449,757,787,

%U 491,503,347,359,907,383,967,593,599,1481,1117,683,1607,467,479,1693

%N Smallest prime number Q such that there is a prime number R such that floor(Q/R)=prime(n).

%H Pierre CAMI, <a href="/A248595/b248595.txt">Table of n, a(n) for n = 1..10000</a>

%e floor(3/2)=1 not prime, floor(5/2)=2=prime(1) so a(1)=5.

%e floor(7/2)=3=prime(2), so a(2)=7.

%e floor(11/2)=5=prime(3), so a(3)=11.

%e floor(13/2)=6 and floor(17/2)=8 not prime, floor(23/3)=7=prime(4), so a(4)=23.

%e floor(23/2)=11=prime(5) so a(5)=23.

%t a[n_] := For[p = Prime[n]; r = 2, True, r = NextPrime[r], For[q = NextPrime[r*p, -1], q <= (p + 1) r, q = NextPrime[q], If[Floor[q/r] == p, Return[q]]]]; Array[a, 100] (* _Jean-Fran├žois Alcover_, Oct 25 2014 *)

%o ( Excel & Visual Basic, the file pre.txt with the first 1000000 prime numbers )

%o Dim p(10000), q(1000000)

%o Open "pre.txt" For Input As #1

%o For i = 1 To 10000: Input #1, x: p(i) = x: q(i) = x: Next i

%o For i = 10001 To 1000000: Input #1, x: q(i) = x: Next i

%o o = 3

%o For l = 1 To 10000

%o x = p(l)

%o For i = 1 To 10000

%o a = p(i)

%o For j = o To 1000000

%o b = q(j)

%o c = Int(b / a)

%o If c < x Then GoTo 5

%o If c = x Then Cells(l, 1) = x: Cells(l, 2) = b: Cells(l, 3)= a: Cells(l, 4).Select: GoTo 20

%o GoTo 10

%o 5 Next j

%o 10 Next i

%o 20 If i = 1 Then o = j

%o Next l

%o End Sub

%Y Cf. A248596.

%K nonn

%O 1,1

%A _Pierre CAMI_, Oct 09 2014

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 December 8 14:38 EST 2019. Contains 329865 sequences. (Running on oeis4.)