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

 

Logo

The OEIS is looking to hire part-time people to help edit core sequences, upload scanned documents, process citations, fix broken links, etc. - Neil Sloane, njasloane@gmail.com

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A232879 The y-axis intercept of the line y = n*x + b tangent to the curve y = prime(k), k = 1, 2, 3, .... 1
1, -1, -5, -13, -37, -83, -194, -469, -1111, -2743, -6698, -16379, -40543, -101251, -254053, -640483, -1622840, -4133371, -10578367, -27130829, -69814219 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,3

COMMENTS

This sequence contains the y intercepts for lines with integer slopes, such that all primes fall at or above the line.  Verified for primes less than 2*10^9.

The first 15 tangent lines intercept prime(k) at the following primes: 2, 3, 5, 7, 13, 19, 23, 31, 43, 47, 113, 283, 1129, 2803, 7043, 24137, 59753, 59797, 155893, 445033, 1195247, 3278837.

LINKS

Table of n, a(n) for n=1..21.

John R Phelan, First 5 integer tangents to prime(n)

FORMULA

n*k + a(n) <= prime(k), where n is the slope, and a(n) is the y intercept.

EXAMPLE

The 2nd tangent line, a(2)+2*k tangent line intercepts p(k) at 3,5,7.

a(n)+n*k = ...

a(2)+2*2 = -1+2*2 = 3 = p(2).

a(2)+2*3 = -1+2*3 = 5 = p(3).

a(2)+2*4 = -1+2*4 = 7 = p(4).

But other primes fall above the 2nd tangent line.

a(2)+2*1 = -1+2*1 = 1 < 2=p(1).

a(2)+2*5 = -1+2*5 = 9 < 11=p(5).

a(2)+2*6 = -1+2*6 = 11 < 13=p(6).

For the 11th tangent line...

a(11)+11*6041 = -6698+6041*11 = 59753 = p(6041).

a(11)+11*6045 = -6698+6045*11 = 59797 = p(6045).

But other primes fall above the 11th tangent line...

a(11)+11*6040 = -6698+6040*11 = 59742 < 59747 = p(6040)

a(11)+11*6042 = -6698+6042*11 = 59764 < 59771 = p(6042)

a(11)+11*6043 = -6698+6043*11 = 59765 < 59779 = p(6043)

a(11)+11*6044 = -6698+6044*11 = 59776 < 59791 = p(6044)

a(11)+11*6046 = -6698+6046*11 = 59798 < 59809 = p(6046)

MATHEMATICA

nn = 10^6; pt = Table[Prime[k], {k, nn}]; Table[r = n*Range[nn] - pt;

mx = Max[r]; Print[{-mx, Flatten[Prime[Position[r, mx]]]}]; -mx, {n, 16}] (* T. D. Noe, Dec 04 2013 *)

PROG

(Java) public class Itp {private static long LIMIT = 10000000; private static long[] a = new long[100]; private static long[] p = new long[100]; public static void main(String[] args) {for (int n = 1; n < a.length; n++) {a[n] = Integer.MAX_VALUE; } long k = 1; for (int i = 2; i < LIMIT; i++) {if (isPrime(i)) {for (int n = 1; n < a.length; n++) {long l = i - n * k; if (l < a[n]) {a[n] = l; p[n] = i; }} k++; }} for (int n = 1; p[n] < LIMIT / 2; n++) {System.out.print(a[n] + ", "); } System.out.println(""); } private static boolean isPrime(int i) {if (i < 2) {return false; } int m = (int) Math.sqrt(i); for (int j = 2; j <= m; j++) {if (i % j == 0) {return false; }} return true; }}

CROSSREFS

Sequence in context: A111057 A019268 A083413 * A269803 A193642 A220709

Adjacent sequences:  A232876 A232877 A232878 * A232880 A232881 A232882

KEYWORD

sign,hard

AUTHOR

John R Phelan, Dec 01 2013

EXTENSIONS

a(16)-a(21) from T. D. Noe, Dec 04 2013

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 | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified May 30 03:31 EDT 2017. Contains 287305 sequences.