cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Previous Showing 21-27 of 27 results.

A072098 Numbers k such that the difference between 10^k and the next prime > 10^k is a record high.

Original entry on oeis.org

1, 3, 7, 12, 16, 21, 28, 62, 97, 118, 122, 135, 164, 218, 333, 346, 387, 443, 485, 521, 630, 819
Offset: 1

Views

Author

Robert G. Wilson v, Jun 18 2002

Keywords

Examples

			For a(22)=819 the difference is 10443 and no other n <= 827 exceeds that difference.
		

Crossrefs

Programs

  • Mathematica
    NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; d = 0; k = 1; Do[ While[f = NextPrim[10^k] - 10^k; d >= f, k++ ]; d = f; Print[k], {n, 1, 50}]

A078728 a(n) is the smallest m such that m < 10^n, 10^n + m is prime and if the natural number k is such that 1 < k < 10 and 3 doesn't divide k*10^n + m then k*10^n+m is prime.

Original entry on oeis.org

3, 57, 297, 177, 237, 25111, 231339, 67419, 273817, 345111, 2001753, 912277, 5236153, 9228627, 10599391, 2835261, 60120003, 14054037, 27923629, 41783347, 24590943, 112161513, 230484021, 11446969, 205242589, 583389307, 873650007
Offset: 1

Views

Author

Farideh Firoozbakht, Dec 26 2003

Keywords

Comments

a(n) is the smallest m such that m < 10^n and all six numbers 10^n + m, (Mod[m, 3]+2)*10^n + m, 4*10^n + m, (Mod[m, 3]+5)*10^n + m, 7*10^n + m & (Mod[m, 3]+8)*10^n + m are primes.
Carlos Rivera in Puzzle 245 of www.primepuzzles.net wrote "if the Faride's results ( a(n) for n=1,...,24 ) are plotted in Excel and a trend 'potential' function is asked, we obtain that a(n) is approximately equal to 0.5*n^6; this means that for n=999 a(n)=5*10^17, approximately." Since 10^n+a(n) is prime, for each n a(n)=0 (mod 3) or a(n)=1 (mod 3).

Examples

			a(6)=25111 because all the six numbers 1025111, 3025111, 4025111, 6025111, 7025111, 9025111 are primes and 25111 is the smallest number with this property.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := (For[m=1, !PrimeQ[10^n+2m-1]||!PrimeQ[(Mod[2m-1, 3]+2)10^n+2m-1]||! PrimeQ[4*10^n+2m-1]||!PrimeQ[(Mod[2m-1, 3]+5)10^n+2m-1]||!PrimeQ [7*10^n+2m-1]||!PrimeQ[(Mod[2m-1, 3]+8)10^n+2m-1], m++ ];2m-1); Do[Print[a[n]], {n, 32}]

Formula

a[n_] := (For[m=1, !PrimeQ[10^n+2m-1]||!PrimeQ[(Mod[2m-1, 3]+2)10^n+2m-1]||! PrimeQ[4*10^n+2m-1]||!PrimeQ[(Mod[2m-1, 3]+5)10^n+2m-1]||!PrimeQ [7*10^n+2m-1]||!PrimeQ[(Mod[2m-1, 3]+8)10^n+2m-1], m++ ];2m-1)

A097519 Prime differences between nextprime(2^n) and 2^n.

Original entry on oeis.org

3, 5, 3, 3, 7, 5, 3, 17, 3, 29, 3, 7, 17, 43, 29, 3, 11, 3, 11, 17, 53, 31, 7, 23, 29, 7, 59, 5, 5, 3, 131, 29, 13, 131, 3, 29, 11, 29, 37, 11, 7, 23, 13, 17, 3, 7, 29, 59, 61, 7, 277, 281, 43, 71, 29, 41, 277, 67, 7, 29, 17, 67, 37, 5, 5, 97, 7, 107, 19, 83, 7, 5, 107, 101
Offset: 1

Views

Author

Cino Hilliard, Aug 27 2004

Keywords

Comments

Primes in A013597. - Bill McEachen, Oct 27 2021

Crossrefs

Programs

  • Mathematica
    Select[Table[NextPrime[2^n]-2^n, {n,200}], PrimeQ] (* Harvey P. Dale, Dec 13 2011 *)
    Select[NextPrime[#]-#&/@(2^Range[200]),PrimeQ] (* Harvey P. Dale, Jan 05 2024 *)

Extensions

Definition corrected by Harvey P. Dale, Dec 13 2011

A120099 Numbers n such that the closest primes surrounding 10^n are the same distance modulo 100.

Original entry on oeis.org

17, 45, 87, 101, 112, 230, 270, 341, 468, 472, 473, 479, 517, 554, 555, 568, 650, 657, 663, 696, 718, 727, 810, 830, 836, 900, 917, 952, 984, 988, 1020, 1021, 1022, 1059, 1140, 1142, 1167, 1200, 1295, 1326, 1400, 1401, 1405, 1406, 1418, 1449, 1499, 1503, 1526
Offset: 1

Views

Author

Keywords

Comments

17 {3, 3}, 45 {9, 9}, 87 {373, 273}, 101 {3, 203}, 112 {207, 807}, 230 {753, 1053}, 270 {361, 861}, 341 {831, 1331}, 468 {301, 801}, 472 {1569, 2669}, 473 {99, 599}, 479 {109, 209}, 554 {937, 437}, 555 {151, 2151}, 568 {501, 801}, 650 {1999, 899}, 657 {1791, 291}, 663 {6333, 33},
696 {61, 1361}, 718 {5863, 1463}, 727 {273, 1073}, 810 {1591, 2891}, 830 {2853, 1253}, 836 {2809, 1209}, 900 {1873, 773}, 917 {693, 5393}, 952 {4827, 27}, 984 {1867, 2867}, 988 {753, 1053}, 1020 {793, 1193}, 1021 {1609, 6209}, 1022 {853, 1053} 1059 {5793, 1293}, 1140 {357, 4857},
1142 {4329, 5829}, 1167 {1131, 3231}, 1200 {5227, 4127}, 1295 {5169, 2369}, 1326 {907, 4007}, 1400 {13317, 2517}, 1401 {10549, 2249}, 1405 {4329, 629}, 1406 {7477, 10277}, 1418 {841, 8741}, 1449 {2989, 3089}, 1499 {2001, 1901}, 1503 {439, 339}, 1526 {4603, 603}, 1534 {2409, 3209}, ...,.

Crossrefs

Programs

  • Mathematica
    NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ@k, k++ ]; k]; PrevPrim[n_] := Block[{k = n - 1}, While[ ! PrimeQ@k, k-- ]; k]; Do[ If[ Mod[ NextPrim[10^n], 100] == Mod[10^n - PrevPrim[10^n], 100], Print[{n, a, b}]], {n, 1320}]
    Select[Range[1530],Mod[NextPrime[10^#]-10^#,100]==Mod[10^# -NextPrime[ 10^#,-1],100]&] (* Harvey P. Dale, Sep 24 2021 *)

Formula

A033873 (mod 100) == A033874 (mod 100).

Extensions

More terms from Robert G. Wilson v, Jun 09 2006
Corrected (term 517 added) by Harvey P. Dale, Sep 25 2021

A124050 Difference between (first Chen prime > 10^n) and 10^n.

Original entry on oeis.org

1, 1, 1, 9, 7, 19, 37, 19, 7, 7, 19, 19, 61, 687, 97, 91, 79, 13, 79, 97, 151, 217, 427, 253, 667, 13, 127, 427, 457, 577, 1069, 349, 1147, 1267, 2527, 2833, 709, 871, 259, 361, 1651, 391, 2689, 649, 31, 3007, 1657, 2257, 3757, 5977, 1441, 2779, 5749, 367, 31
Offset: 0

Views

Author

Zak Seidov, Nov 03 2006

Keywords

Comments

A033873(n) <= a(n) <= A124001(n) and a(n) = A033873(n) for n = 0, 1, 2, 3, 4, 7, 8, 9, 10, 25, 44, 54.

Examples

			a(0) = 1 because 2 is prime, 2 + 2 = 4 semiprime and 2 - 10^0 = 1,
a(1) = 1 because 11 and 13 are twin primes and 11 - 10^1 = 1,
a(2) = 1 because 101 and 103 are twin primes and 101 - 10^2 = 1,
a(3) = 9 because 1009 is prime, 1011 = 3*337 semiprime and 1009 - 10^3 = 9,
a(4) = 7 because 10007 and 10009 are twin primes and 10007 - 10^4 = 7,
a(5) = 19 because 100019 is prime, 100021 = 29*3449 semiprime and 100019 - 10^5 = 19, etc.
		

Crossrefs

A214506 Last digit of the smallest prime number in base 10 with n digits.

Original entry on oeis.org

2, 1, 1, 9, 7, 3, 3, 9, 7, 7, 9, 3, 9, 7, 1, 7, 1, 3, 3, 1, 9, 7, 9, 7, 7, 3, 7, 3, 1, 9, 7, 3, 9, 1, 3, 9, 7, 3, 3, 3, 1, 9, 3, 7, 1, 9, 1, 3, 3, 9, 1, 1, 7, 1, 1, 1, 3, 9, 9, 9, 7, 3, 7, 1, 7, 9, 9, 9, 9, 9, 3, 3, 9, 9, 7, 9, 3, 1, 3, 9, 9, 3, 1, 7, 1, 3
Offset: 1

Views

Author

Tjandra Satria Gunawan, Jul 19 2012

Keywords

Comments

The last digit of the first prime number in base 10 with n digits for n = 1, 2, 3 is 211, because 2 is the least with 1 digit, 11 the least with 2 digits, 101 the least with 3 digits. The concatenation, 211, is prime. This does not happen again through 24 digits. - Jonathan Vos Post, Jul 04 2012

Programs

  • Mathematica
    Table[Mod[NextPrime[10^n],10],{n,0,30}] (* Harvey P. Dale, Jan 25 2013 *)

Formula

a(1) = 2, and a(n) = A033873(n) mod 10 for n>1.
a(n) = A003617(n) mod 10. - Michel Marcus, Aug 06 2013

Extensions

More terms from Harvey P. Dale, Jan 25 2013

A272006 a(n) = A003617(n) - A062397(n-1).

Original entry on oeis.org

0, 0, 0, 8, 6, 2, 2, 18, 6, 6, 18, 2, 38, 36, 30, 36, 60, 2, 2, 50, 38, 116, 8, 116, 6, 12, 66, 102, 330, 318, 56, 32, 48, 60, 192, 68, 66, 42, 132, 2, 120, 108, 62, 56, 30, 8, 120, 32, 192, 8, 150, 120, 326, 170, 30, 20, 2, 278, 158, 18, 6, 92, 446, 120, 56, 48, 48, 48, 98, 8, 32, 272, 38, 78, 206
Offset: 1

Views

Author

Carauleanu Marc, Jul 13 2016

Keywords

Examples

			For n=4, the smallest 4-digit prime is 1009, and 10^(4-1) + 1 = 1001, so a(4) = 1009 - 1001 = 8. - _Michael B. Porter_, Aug 01 2016
		

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[#] - (# + 1) &[10^(n - 1)], {n, 75}] (* Michael De Vlieger, Jul 13 2016 *)
  • PARI
    a(n) = nextprime(10^(n-1)) - (10^(n-1) +  1); \\ Michel Marcus, Jul 28 2016

Formula

a(n) = A033873(n-1) - 1. - Michel Marcus, Jul 28 2016
Previous Showing 21-27 of 27 results.