A153275
Numbers n such that 10*n+1 is not prime.
Original entry on oeis.org
0, 2, 5, 8, 9, 11, 12, 14, 16, 17, 20, 22, 23, 26, 29, 30, 32, 34, 35, 36, 37, 38, 39, 41, 44, 45, 47, 48, 50, 51, 53, 55, 56, 58, 59, 61, 62, 65, 67, 68, 71, 72, 73, 74, 77, 78, 79, 80, 83, 84, 85, 86, 87, 89, 90, 92, 93, 95, 96, 98, 100, 101, 104, 107, 108, 110
Offset: 1
Distribution of the terms in the following triangular array:
*;
*,*;
2,*,*;
*,*,*,8;
*,*,*,*,12;
*,*,9,*,*,*;
*,*,*,*,*,*,*;
5,*,*,*,*,22,*,*;
*,*,*,17,*,*,*,*,36;
*,*,*,*,23,*,*,*,*,44;
*,*,16,*,*,*,*,39,*,*,*; etc.
where * marks the non-integer values of (2*h*k + k + h)/5 with h >= k >= 1. - _Vincenzo Librandi_, Jan 15 2013
A343717
a(n) is the smallest number that yields a prime when appended to n!.
Original entry on oeis.org
1, 1, 3, 1, 1, 1, 7, 11, 29, 17, 43, 29, 13, 47, 19, 73, 37, 19, 41, 103, 41, 31, 43, 1, 113, 31, 37, 59, 41, 53, 41, 47, 1, 41, 149, 37, 53, 73, 337, 1, 103, 151, 293, 47, 107, 509, 127, 71, 167, 197, 167, 149, 67, 163, 139, 251, 59, 107, 241, 331, 269, 1, 149
Offset: 0
n=1: 1! = 1; appending a 1 yields 11, a prime, so a(1)=1.
n=2: 2! = 2; appending a 1 yields 21 = 3*7, and appending a 2 yields 22 = 2*11, but appending a 3 yields 23 (a prime), so a(2)=3.
n=19: 19! = 121645100408832000; appending any number < 103 yields a composite, but 121645100408832000103 is a prime, so a(19)=103.
-
a:= proc(n) option remember; local k, t; t:= n!;
for k while not isprime(parse(cat(t, k))) do od; k
end:
seq(a(n), n=0..62); # Alois P. Heinz, May 17 2021
-
Array[Block[{m = #!, k = 0}, While[! PrimeQ[10^If[k == 0, 1, IntegerLength[k]]*m + k], k++]; k] &, 62] (* Michael De Vlieger, May 17 2021 *)
snp[n_]:=Module[{nf=n!,c=1},While[!PrimeQ[nf*10^IntegerLength[c]+c],c++];c]; Array[snp,70,0] (* Harvey P. Dale, Oct 17 2024 *)
-
for(n=0,62,my(f=digits(n!));forstep(k=1,oo,2,my(p=fromdigits(concat(f,digits(k))));if(ispseudoprime(p),print1(k,", ");break))) \\ Hugo Pfoertner, May 18 2021
-
# see link for faster program producing b-file
from sympy import factorial, isprime
def a(n):
start = str(factorial(n))
end = 1
while not isprime(int(start + str(end))): end += 2
return end
print([a(n) for n in range(63)]) # Michael S. Branicky, May 17 2021
A102249
Numbers k such that k1111 is prime.
Original entry on oeis.org
10, 13, 31, 36, 51, 57, 61, 69, 72, 78, 79, 90, 91, 97, 117, 120, 127, 129, 135, 138, 153, 156, 166, 174, 183, 184, 189, 201, 205, 210, 222, 225, 226, 234, 237, 240, 241, 244, 252, 261, 265, 273, 276, 280, 285, 292, 304, 306, 309, 318, 322, 325, 327, 337, 345
Offset: 1
At k=10, k1111 = 101111 (prime).
At k=90, k1111 = 901111 (prime).
At k=138, k1111 = 1381111 (prime).
-
Select[ Range[ 350], PrimeQ[ FromDigits[ Flatten[ IntegerDigits /@ { #, 1, 1, 1, 1}]]] &] (* Robert G. Wilson v, Feb 21 2005 *)
Select[Range[400],PrimeQ[#*10^4+1111]&] (* Harvey P. Dale, Jul 14 2019 *)
A078656
a(n) = prime(k) where k = n-th prime congruent to 1 mod 10.
Original entry on oeis.org
31, 127, 179, 283, 353, 547, 739, 877, 1087, 1153, 1297, 1523, 1597, 1741, 1823, 2063, 2221, 2749, 2909, 3001, 3259, 3517, 3733, 3911, 4153, 4421, 4663, 4759, 4943, 5189, 5281, 5701, 5801, 6229, 6311, 6841, 7109
Offset: 1
-
Prime[10Select[Range[110], PrimeQ[10# + 1] &] + 1]
Prime[#]&/@Select[Prime[Range[200]],NumberDigit[#,0]==1&] (* Requires Mathematica version 12 or later *) (* Harvey P. Dale, May 31 2021 *)
-
pip(n,m,r) = {sr=0; forprime(x=3,n, if(x%m == r,v=prime(x); sr+=1.0/v; print1(v" "); ) ); print(); print("m="m" r="r" sr="sr); }
A089767
Squares which when concatenated with a 1 gives prime.
Original entry on oeis.org
1, 4, 25, 49, 64, 81, 225, 400, 676, 784, 900, 1089, 1225, 1369, 1600, 1681, 2209, 2304, 3249, 3364, 4096, 5041, 6889, 7225, 7396, 8100, 8281, 8649, 9801, 10816, 11025, 11236, 12100, 12544, 12769, 13924, 15876, 16384, 17424, 19881, 21609, 21904
Offset: 1
41, 4001, 6761 etc. are primes.
-
A = []; count = 0; i = 1; while count < 60; s = i*i; if isprime(10*s + 1) A = [A s]; count = count + 1; end; i = i + 1; end; A
-
select(t -> isprime(10*t+1), map(`^`,[$1..300],2)); # Robert Israel, Dec 09 2017
-
Select[Range[150]^2, PrimeQ[10 # + 1] &] (* Michael De Vlieger, Dec 09 2017 *)
A102546
Numbers t such that t1 is prime and t is a multiple of 10.
Original entry on oeis.org
10, 40, 60, 70, 120, 130, 160, 180, 190, 280, 300, 330, 370, 400, 420, 480, 510, 550, 570, 580, 610, 630, 670, 700, 790, 810, 850, 900, 960, 990, 1030, 1050, 1060, 1170, 1180, 1210, 1230, 1240, 1260, 1300, 1390, 1440, 1510, 1540, 1560, 1590, 1600, 1630, 1690, 1740, 1830, 1840, 1870
Offset: 1
If t=10, then t1 = 101 (prime).
If t=180, then t1 = 1801 (prime).
If t=420, then t1 = 4201 (prime).
A108857
Numbers n such that 10*n + 131 is prime.
Original entry on oeis.org
0, 2, 5, 6, 8, 11, 12, 14, 15, 18, 20, 27, 29, 30, 33, 36, 39, 41, 44, 47, 50, 51, 53, 56, 57, 62, 63, 68, 69, 75, 78, 81, 84, 86, 89, 90, 92, 93, 96, 102, 104, 105, 107, 110, 116, 117, 119, 123, 125, 132, 134, 135, 138, 140, 144, 147, 149, 159, 161, 167, 168, 170, 173
Offset: 1
If n=0 then 10*n + 131 = 131 (prime).
If n=33 then 10*n + 131 = 461 (prime).
A243962
Primes p such that 10p + 1, 100p + 1 and 1000p + 1 are also primes.
Original entry on oeis.org
7, 13, 19, 103, 823, 1021, 1579, 1867, 2503, 3331, 5779, 6871, 6949, 9007, 10093, 10399, 11317, 11743, 13327, 13381, 15859, 16657, 17539, 17659, 22189, 26317, 26557, 26821, 27397, 27943, 29209, 29383, 30211, 32443, 37309, 38287, 40213, 40507, 44497, 47569, 47977
Offset: 1
7 is in the sequence because 7 is prime, 10*7 + 1 = 71 is prime, 100*7 + 1 = 701 is prime, and 1000*7 + 1 = 7001 is prime.
-
with(numtheory):A243962:= proc() local p; p:=ithprime(n); if isprime(10*p+1) and isprime(100*p+1) and isprime(1000*p+1) then RETURN (p); fi; end: seq(A243962 (), n=1..5000);
-
Select[Prime[Range[10000]], PrimeQ[10 # + 1] && PrimeQ[100 # + 1] && PrimeQ[1000 # + 1] &]
A125869
Numbers k such that p=10*k+1 is prime and cos(2*Pi/p) is an algebraic number of a 5-smooth degree, but not 3-smooth.
Original entry on oeis.org
1, 3, 4, 6, 10, 15, 18, 24, 25, 27, 40, 54, 60, 64, 75, 81, 120, 160, 162, 180, 216, 225, 300, 400, 405, 480, 486, 648, 768, 810, 864, 900, 960, 972, 1125, 1440, 1536, 1600, 1944, 2160, 2187, 2250, 2304, 2400, 2560, 3240, 3375, 3645, 3750, 4096, 4320
Offset: 1
-
Do[If[Take[FactorInteger[EulerPhi[10n+1]][[ -1]],1]=={5} && PrimeQ[10n+1],Print[n]],{n,1,10000}]
Comments