A002822
Numbers m such that 6m-1, 6m+1 are twin primes.
Original entry on oeis.org
1, 2, 3, 5, 7, 10, 12, 17, 18, 23, 25, 30, 32, 33, 38, 40, 45, 47, 52, 58, 70, 72, 77, 87, 95, 100, 103, 107, 110, 135, 137, 138, 143, 147, 170, 172, 175, 177, 182, 192, 205, 213, 215, 217, 220, 238, 242, 247, 248, 268, 270, 278, 283, 287, 298, 312, 313, 322, 325
Offset: 1
- W. J. LeVeque, Topics in Number Theory. Addison-Wesley, Reading, MA, 2 vols., 1956, Vol. 1, p. 69.
- W. Sierpiński, A Selection of Problems in the Theory of Numbers. Macmillan, NY, 1964, p. 120.
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- T. D. Noe, Table of n, a(n) for n = 1..10000
- F. Balestrieri, An Equivalent Problem To The Twin Prime Conjecture, arXiv:1106.6050v1 [math.GM], 2011.
- A. Dinculescu, On Some Infinite Series Related to the Twin Primes, The Open Mathematics Journal, 5 (2012), 8-14.
- A. Dinculescu, The Twin Primes Seen from a Different Perspective, The British Journal of Mathematics & Computer Science, 3 (2013), Issue 4, 691-698.
- A. Dinculescu, On the Numbers that Determine the Distribution of Twin Primes, Surveys in Mathematics and its Applications, 13 (2018), 171-181.
- S. W. Golomb, Problem E969, Solution, Amer. Math. Monthly, 58 (1951), 338; 59 (1952), 44.
- S. W. Golomb, Letter to N. J. A. Sloane, Mar 26 1984
- Matthew A. Myers, Comments on A002822, Letter to N. J. A. Sloane, Dec 04 2018
-
a002822 n = a002822_list !! (n-1)
a002822_list = f a000040_list where
f (q:ps'@(p:ps)) | p > q + 2 || r > 0 = f ps'
| otherwise = y : f ps where (y,r) = divMod (q + 1) 6
-- Reinhard Zumkeller, Jul 13 2014
-
[n: n in [1..200] | IsPrime(6*n+1) and IsPrime(6*n-1)] // Vincenzo Librandi, Nov 21 2010
-
select(n -> isprime(6*n-1) and isprime(6*n+1), [$1..1000]); # Robert Israel, Jan 11 2015
-
Select[ Range[350], PrimeQ[6# - 1] && PrimeQ[6# + 1] & ]
Select[Range[400],AllTrue[6#+{1,-1},PrimeQ]&] (* Harvey P. Dale, Jul 27 2022 *)
#/6&/@Select[Range[6,2500,6],AllTrue[#+{1,-1},PrimeQ]&] (* Harvey P. Dale, Mar 31 2023 *)
-
select(primes(100),n->isprime(n-2)&&n>5)\6 \\ Charles R Greathouse IV, Jul 05 2011
-
p=5; forprime(q=5, 1e4, if(q-p==2, print1((p+1)/6", ")); p=q); \\ Altug Alkan, Oct 13 2015
-
list(lim)=my(v=List(),p=5); forprime(q=7,6*lim+1, if(q-p==2, listput(v,q\6)); p=q); Vec(v) \\ Charles R Greathouse IV, Dec 03 2016
More terms from Larry Reeves (larryr(AT)acm.org), Mar 27 2001
A038509
Composite numbers congruent to +-1 mod 6.
Original entry on oeis.org
25, 35, 49, 55, 65, 77, 85, 91, 95, 115, 119, 121, 125, 133, 143, 145, 155, 161, 169, 175, 185, 187, 203, 205, 209, 215, 217, 221, 235, 245, 247, 253, 259, 265, 275, 287, 289, 295, 299, 301, 305, 319, 323, 325, 329, 335, 341, 343, 355, 361, 365, 371, 377, 385
Offset: 1
Cf.
A171993 (nonprimes of the form 3*k+-1).
-
a038509 n = a038509_list !! (n-1)
a038509_list = [x | x <- a002808_list, gcd x 6 == 1]
-- Reinhard Zumkeller, Aug 05 2014, Jun 30 2012
-
A038509 := proc(n)
option remember;
if n = 1 then
25;
else
for a from procname(n-1)+1 do
if not isprime(a) and modp(a,6) in {1,5} then
return a;
end if;
end do:
end if;
end proc:
seq(A038509(n),n=1..30) ; # R. J. Mathar, Feb 28 2020
-
Select[Range[1000], FactorInteger[#][[1,1]] >= 5 && ! PrimeQ[#] &] (* Robert G. Wilson v, Dec 19 2009 *)
With[{nn=400},Select[Rest[Complement[Range[nn],Prime[Range[ PrimePi[ nn]]]]], MemberQ[ {1,5},Mod[#,6]]&]] (* Harvey P. Dale, Feb 21 2013 *)
Select[Range[400],CompositeQ[#]&&MemberQ[{1,5},Mod[#,6]]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, May 13 2019 *)
-
is(n)=gcd(n,6)==1 && !isprime(n) && n>7 \\ Charles R Greathouse IV, Nov 20 2012
A046953
Numbers k such that 6*k - 1 is composite.
Original entry on oeis.org
6, 11, 13, 16, 20, 21, 24, 26, 27, 31, 34, 35, 36, 37, 41, 46, 48, 50, 51, 54, 55, 56, 57, 61, 62, 63, 66, 68, 69, 71, 73, 76, 79, 81, 83, 86, 88, 89, 90, 91, 92, 96, 97, 101, 102, 104, 105, 106, 111, 112, 115, 116, 118, 119, 121, 122, 123, 125, 126, 128
Offset: 1
a(1)=6 because 6*6 - 1 = 35, which is composite.
-
Filtered([1..200], k-> not IsPrime(6*k-1)) # G. C. Greubel, Feb 21 2019
-
a046953 n = a046953_list !! (n-1)
a046953_list = map (`div` 6) $
filter ((== 0) . a010051' . subtract 1) [6,12..]
-- Reinhard Zumkeller, Jul 13 2014
-
[n: n in [1..200] | not IsPrime(6*n-1)]; // G. C. Greubel, Feb 21 2019
-
remove(k-> isprime(6*k-1), [$1..130])[]; # Muniru A Asiru, Feb 22 2019
-
Select[Range[200],!PrimeQ[6#-1]&] (* Vladimir Joseph Stephan Orlovsky, Feb 25 2011 *)
-
is(n)=!isprime(6*n-1) \\ Charles R Greathouse IV, Aug 01 2016
-
[n for n in (1..200) if not is_prime(6*n-1)] # G. C. Greubel, Feb 21 2019
A046954
Numbers k such that 6*k + 1 is nonprime.
Original entry on oeis.org
0, 4, 8, 9, 14, 15, 19, 20, 22, 24, 28, 29, 31, 34, 36, 39, 41, 42, 43, 44, 48, 49, 50, 53, 54, 57, 59, 60, 64, 65, 67, 69, 71, 74, 75, 78, 79, 80, 82, 84, 85, 86, 88, 89, 92, 93, 94, 97, 98, 99, 104, 106, 108, 109, 111, 113, 114, 116, 117, 119, 120, 124, 127, 129, 130, 132, 133, 134, 136, 139, 140
Offset: 1
a(2)=8 because 6*8 + 1 = 49, which is composite.
-
Filtered([0..250], k-> not IsPrime(6*k+1)) # G. C. Greubel, Feb 21 2019
-
a046954 n = a046954_list !! (n-1)
a046954_list = map (`div` 6) $ filter ((== 0) . a010051' . (+ 1)) [0,6..]
-- Reinhard Zumkeller, Jul 13 2014
-
[n: n in [0..250] | not IsPrime(6*n+1)]; // G. C. Greubel, Feb 21 2019
-
remove(k-> isprime(6*k+1), [$0..140])[]; # Muniru A Asiru, Feb 22 2019
-
a = Flatten[Table[If[PrimeQ[6*n + 1] == False, n, {}], {n, 0, 50}]] (* Roger L. Bagula, May 17 2007 *)
Select[Range[0, 200], !PrimeQ[6 # + 1] &] (* Vincenzo Librandi, Sep 27 2013 *)
-
is(n)=!isprime(6*n+1) \\ Charles R Greathouse IV, Aug 01 2016
-
[n for n in (0..250) if not is_prime(6*n+1)] # G. C. Greubel, Feb 21 2019
A070043
Numbers of the form 6*j*k+j+k for positive integers j and k.
Original entry on oeis.org
8, 15, 22, 28, 29, 36, 41, 43, 50, 54, 57, 60, 64, 67, 71, 78, 79, 80, 85, 92, 93, 98, 99, 104, 106, 113, 117, 119, 120, 127, 129, 132, 134, 136, 141, 145, 148, 154, 155, 158, 160, 162, 169, 171, 174, 176, 179, 183, 184, 190, 191, 193, 197, 204, 210, 211, 212
Offset: 1
41 = 6*2*3 + 2 + 3. Equivalently, 6*41+1 = (6*2+1)*(6*3+1).
-
Select[Range[250], MemberQ[Mod[Take[Divisors[6#+1], {2, -2}], 6], 1]&]
A307561
Numbers k such that both 6*k - 1 and 6*k + 5 are prime.
Original entry on oeis.org
1, 2, 3, 4, 7, 8, 9, 14, 17, 18, 22, 28, 29, 32, 38, 39, 42, 43, 44, 52, 58, 59, 64, 74, 77, 84, 93, 94, 98, 99, 107, 108, 109, 113, 137, 143, 147, 157, 158, 162, 163, 169, 182, 183, 184, 197, 198, 203, 204, 213, 214, 217, 227, 228, 238, 239, 247, 248, 249, 259, 267, 268, 269, 312, 317, 318, 329, 333, 344
Offset: 1
a(2) = 2, so 6(2) - 1 = 11 and 6(2) + 5 = 17 are both prime.
-
Select[Range[500], PrimeQ[6# - 1] && PrimeQ[6# + 5] &] (* Alonso del Arte, Apr 14 2019 *)
-
is(k) = isprime(6*k-1) && isprime(6*k+5); \\ Jinyuan Wang, Apr 20 2019
A307562
Numbers k such that both 6*k + 1 and 6*k + 7 are prime.
Original entry on oeis.org
1, 2, 5, 6, 10, 11, 12, 16, 17, 25, 26, 32, 37, 45, 46, 51, 55, 61, 62, 72, 76, 90, 95, 100, 101, 102, 121, 122, 125, 137, 142, 146, 165, 172, 177, 181, 186, 187, 205, 215, 216, 220, 237, 241, 242, 247, 257, 270, 276, 277, 282, 290, 291, 292, 296, 297, 310, 311, 312, 331, 332, 335, 347, 355, 356, 380, 381, 390
Offset: 1
a(3) = 5, so 6(5) + 1 = 31 and 6(5) + 7 = 37 are both prime.
-
Select[Range[400], AllTrue[6 # + {1, 7}, PrimeQ] &] (* Michael De Vlieger, Apr 15 2019 *)
-
isok(n) = isprime(6*n+1) && isprime(6*n+7); \\ Michel Marcus, Apr 16 2019
A307563
Numbers k such that both 6k - 1 and 6k + 7 are prime.
Original entry on oeis.org
1, 2, 4, 5, 9, 10, 12, 15, 17, 22, 25, 29, 32, 39, 44, 45, 60, 65, 67, 72, 75, 80, 82, 94, 95, 99, 100, 109, 114, 117, 120, 124, 127, 137, 152, 155, 164, 169, 172, 177, 185, 194, 199, 204, 205, 214, 215, 220, 229, 240, 242, 247, 254, 260, 262, 267, 269, 270, 289, 304, 312, 330, 334, 347, 355, 359, 369, 374, 379, 389
Offset: 1
a(4) = 5, so 6(5) - 1 = 29 and 6(5) + 7 = 37 are both prime.
-
select(t -> isprime(6*t-1) and isprime(6*t+7), [$1..500]); # Robert Israel, May 27 2019
-
isok(n) = isprime(6*n-1) && isprime(6*n+7); \\ Michel Marcus, Apr 16 2019
A070799
Numbers of the form 6jk-j-k.
Original entry on oeis.org
4, 9, 14, 19, 20, 24, 29, 31, 34, 39, 42, 44, 48, 49, 53, 54, 59, 64, 65, 69, 74, 75, 79, 82, 84, 86, 88, 89, 94, 97, 99, 104, 108, 109, 111, 114, 116, 119, 124, 129, 130, 133, 134, 139, 140, 141, 144, 149, 150, 152, 154, 157, 159, 163, 164, 167, 169, 174, 179, 180
Offset: 1
31 = 6*2*3 - 2 - 3. Equivalently, 6*31+1 = (6*2-1)*(6*3-1).
-
Select[Range[250], MemberQ[Mod[Take[Divisors[6#+1], {2, -2}], 6], 5]&]
A323674
Square array, read by antidiagonals, of the positive integers 6cd +-c +-d = (6c +- 1)d +- c. Alternate rows (or columns) are numbers that differ by c from multiples of 6c - 1 or 6c + 1.
Original entry on oeis.org
4, 6, 6, 9, 8, 9, 11, 13, 13, 11, 14, 15, 20, 15, 14, 16, 20, 24, 24, 20, 16, 19, 22, 31, 28, 31, 22, 19, 21, 27, 35, 37, 37, 35, 27, 21, 24, 29, 42, 41, 48, 41, 42, 29, 24, 26, 34, 46, 50, 54, 54, 50, 46, 34, 26, 29, 36, 53, 54, 65, 60, 65, 54, 53, 36, 29, 31, 41, 57, 63, 71, 73, 73, 71, 63, 57, 41, 31
Offset: 1
Square array begins:
4, 6, 9, 11, 14, 16, 19, 21, 24, 26, ...
6, 8, 13, 15, 20, 22, 27, 29, 34, 36, ...
9, 13, 20, 24, 31, 35, 42, 46, 53, 57, ...
11, 15, 24, 28, 37, 41, 50, 54, 63, 67, ...
14, 20, 31, 37, 48, 54, 65, 71, 82, 88, ...
16, 22, 35, 41, 54, 60, 73, 79, 92, 98, ...
19, 27, 42, 50, 65, 73, 88, 96, 111, 119, ...
21, 29, 46, 54, 71, 79, 96, 104, 121, 129, ...
24, 34, 53, 63, 82, 92, 111, 121, 140, 150, ...
26, 36, 57, 67, 88, 98, 119, 129, 150, 160, ...
...
Note that, for example, the third row (or column) contains numbers that differ by 2 from multiples of 11 = 6*2 - 1, and the eighth row contains numbers that differ by 4 from multiples of 25 = 6*4 + 1.
The diagonal is
A062717, the numbers x for which 6*x + 1 is a perfect square.
-
a(m,n) = 6*floor((m+1)/2)*floor((n+1)/2) + ((-1)^n)*floor((m+1)/2) + ((-1)^m)*floor((n+1)/2);
matrix(7, 7, n, k, a(n, k)) \\ Michel Marcus, Jan 25 2019
Showing 1-10 of 16 results.
Comments