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.

Showing 1-8 of 8 results.

A111153 Sophie Germain semiprimes: semiprimes n such that 2n+1 is also a semiprime.

Original entry on oeis.org

4, 10, 25, 34, 38, 46, 55, 57, 77, 91, 93, 106, 118, 123, 129, 133, 143, 145, 159, 161, 169, 177, 185, 201, 203, 205, 206, 213, 218, 226, 235, 259, 267, 289, 291, 295, 298, 305, 314, 327, 334, 335, 339, 358, 361, 365, 377, 381, 394, 395, 403, 407, 415, 417
Offset: 1

Views

Author

Christopher M. Tomaszewski (cmt1288(AT)comcast.net), Oct 19 2005

Keywords

Comments

Define a generalized Sophie Germain n-prime of degree m, p, to be an n-prime (n-almost prime) such that 2p+1 is an m-prime (m-almost prime). For example, p=24 is a Sophie Germain 4-prime of degree 2 because 24 is a 4-prime and 2*24+1=49 is a 2-prime. Then this sequence gives all the Sophie Germain 2-primes of degree 2.

Examples

			a(4)=34 because 34 is the 4th semiprime such that 2*34+1=69 is also a semiprime.
		

Crossrefs

Programs

  • Magma
    f:=func< n | &+[k[2]: k in Factorization(n)] eq 2 >; [ n: n in [4..500] | f(n) and f(2*n+1)]; // Marius A. Burtea, Jan 04 2019
    
  • Mathematica
    SemiPrimeQ[n_] := (Plus@@Transpose[FactorInteger[n]][[2]]==2); Select[Range[2, 500], SemiPrimeQ[ # ]&&SemiPrimeQ[2#+1]&] (* T. D. Noe, Oct 20 2005 *)
    fQ[n_] := Plus @@ Last /@ FactorInteger[n] == 2; Select[ Range[445], fQ[ # ] && fQ[2# + 1] &] (* Robert G. Wilson v, Oct 20 2005 *)
    Flatten@Position[PrimeOmega@{#,1+2*#}&/@Range@1000,{2,2}] (* Hans Rudolf Widmer, Nov 25 2023 *)
  • PARI
    isok(n) = (bigomega(n) == 2) && (bigomega(2*n+1) == 2); \\ Michel Marcus, Jan 04 2019

Formula

a(n) = (A176896(n) - 1)/2. - Zak Seidov, Sep 10 2012

Extensions

Corrected and extended by T. D. Noe, Ray Chandler and Robert G. Wilson v, Oct 20 2005

A111173 Sophie Germain triprimes: k and 2k + 1 are both the product of 3 primes, not necessarily distinct.

Original entry on oeis.org

52, 76, 130, 171, 172, 212, 238, 318, 322, 325, 332, 357, 370, 387, 388, 402, 423, 430, 436, 442, 465, 507, 508, 556, 604, 610, 654, 665, 670, 710, 722, 747, 759, 762, 772, 775, 786, 790, 805, 814, 822, 826, 847, 874, 885, 902, 906, 916, 927, 942, 987, 1004
Offset: 1

Views

Author

Jonathan Vos Post, Oct 21 2005

Keywords

Comments

There should also be triprime chains of length j analogous to Cunningham chains of the first kind and Tomaszewski chains of the first kind. A triprime chain of length j is a sequence of triprimes a(1) < a(2) < ... < a(j) such that a(i+1) = 2*a(i) + 1 for i = 1, ..., j-1. The first of these are: Length 3: 332, 665, 1331 = 11^3; 387, 775, 1551 = 3 * 11 * 47.

Examples

			n      k = a(n)           2k + 1
=  ================  ================
1   52 = 2^2 * 13    105 = 3 * 5 * 7
2   76 = 2^2 * 19    153 = 3^2 * 17
3  130 = 2 * 5 * 13  261 = 3^2 * 29
4  171 = 3^2 * 19    343 = 7^3
5  172 = 2^2 * 43    345 = 3 * 5 * 23
6  212 = 2^2 * 53    425 = 5^2 * 17
		

Crossrefs

Programs

  • Magma
    Is3primes:=func; [n: n in [2..1200] | Is3primes(n) and Is3primes(2*n+1)]; // Vincenzo Librandi, Aug 19 2018
  • Mathematica
    fQ[n_]:=PrimeOmega[n] == 3 == PrimeOmega[2 n + 1]; Select[Range@1100, fQ] (* Vincenzo Librandi, Aug 19 2018 *)
  • PARI
    is(n)=bigomega(n)==3 && bigomega(2*n+1)==3 \\ Charles R Greathouse IV, Feb 01 2017
    

Formula

{a(n)} = a(n) is an element of A014612 and 2*a(n)+1 is an element of A014612.

Extensions

Extended by Ray Chandler, Oct 22 2005
Edited by Jon E. Schoenfield, Aug 18 2018

A111168 Semiprimes n such that 2*n - 1 is also a semiprime.

Original entry on oeis.org

25, 26, 33, 35, 39, 46, 58, 62, 65, 85, 93, 94, 111, 118, 119, 133, 134, 145, 146, 155, 161, 178, 183, 202, 206, 209, 214, 219, 226, 235, 237, 247, 249, 253, 259, 265, 267, 287, 291, 295, 299, 334, 335, 341, 361, 362, 377, 382, 386, 391, 393, 395, 407, 422
Offset: 1

Views

Author

Jonathan Vos Post, Oct 21 2005

Keywords

Comments

Define an m-th degree Tomaszewski n-chain of the first (second) kind and length k to be a sequence of n-almost primes p(1) < p(2) < ... < p(k) such that s(i+1) = m*s(i) +(-) 1 for i = 1, ..., k-1. Notice that a 2nd degree Tomaszewski 1-chain of the first (second) kind is the familiar Cunningham chain of the first (second) kind.

Examples

			n s(n) s*2-1
1 25 = 5^2 49 = 7^2
2 26 = 2 * 13 51 = 3 * 17
3 33 = 3 * 11 65 = 5 * 13
4 35 = 5 * 7 69 = 3 * 23
5 39 = 3 * 13 77 = 7 * 11
		

Crossrefs

Programs

  • Mathematica
    Select[Range[500],PrimeOmega[#]==PrimeOmega[2#-1]==2&]  (* Harvey P. Dale, Jul 23 2025 *)
  • PARI
    is(n)=bigomega(n)==2 && bigomega(2*n-1)==2 \\ Charles R Greathouse IV, Jan 31 2017

Formula

{a(n)} = a(n) is an element of A001358 and 2*a(n)-1 is an element of A001358.

Extensions

Extended by Ray Chandler, Oct 22 2005

A111170 Semiprimes S such that 3*S + 1 is also a semiprime.

Original entry on oeis.org

15, 35, 38, 39, 55, 62, 82, 86, 87, 91, 106, 111, 115, 118, 119, 134, 142, 155, 159, 178, 187, 194, 218, 226, 235, 254, 259, 267, 278, 287, 295, 298, 299, 314, 319, 326, 327, 334, 335, 339, 371, 382, 386, 391, 395, 398, 411, 422, 427, 446, 451, 454, 502, 515
Offset: 1

Views

Author

Jonathan Vos Post, Oct 21 2005

Keywords

Comments

This is analogous to Sophie Germain semiprimes A111153 and the chains shown are analogous to Cunningham chains of the first kind and Tomaszewski chains of the first kind. Define a 3n+1 semiprime chain of length k. This is a sequence of semiprimes s(1) < s(2) < ... < s(k) such that s(i+1) = 3*s(i) + 1 for i = 1, ..., k-1. Length 3: 111, 334, 1003; 142, 427, 1282. Length 4: 35, 106, 319, 958; 86, 259, 778, 2335; 187, 562, 1687, 5062.
a(n) is either an even semiprime 2*k where k is a prime such that 6*k+1 is a semiprime, or an odd semiprime 2*k+1 where 3*k+2 is a prime. - Robert Israel, Dec 10 2024

Examples

			n s(n) 3*s + 1
1 15 = 3 * 5 46 = 2 * 23
2 35 = 5 * 7 106 = 2 * 53
3 38 = 2 * 19 115 = 5 * 23
4 39 = 3 * 13 118 = 2 * 59
5 55 = 5 * 11 166 = 2 * 83
6 62 = 2 * 31 187 = 11 * 17
		

Crossrefs

Programs

  • Maple
    q:= n-> andmap(x-> 2=numtheory[bigomega](x), [n, 3*n+1]):
    select(q, [$4..515])[];  # Alois P. Heinz, May 02 2024
    # alternative
    N:= 10^4: # to get all terms < (N-1)/3
    Primes:= select(isprime, [2, seq(2*k+1, k=1..floor(N/2))]):
    SP:={seq(seq(p*q, q=Primes[1..ListTools:-BinaryPlace(Primes, N/p)]), p=Primes)} minus {seq(p^2, p=Primes)}:
    sort(convert(SP intersect map(t -> (t-1)/3, SP), list)); # Robert Israel, Dec 10 2024
  • Mathematica
    Select[Range[515],PrimeOmega[#]==2&&PrimeOmega[3*#+1]==2&] (* James C. McMahon, May 01 2024 *)

Formula

{a(n)} = a(n) is an element of A001358 and 3*a(n)+1 is an element of A001358.

Extensions

Extended by Ray Chandler, Oct 22 2005

A111171 Semiprimes S such that 3*S - 1 is also a semiprime.

Original entry on oeis.org

9, 21, 22, 25, 26, 49, 62, 65, 69, 74, 85, 93, 121, 122, 129, 133, 141, 146, 158, 161, 166, 178, 185, 194, 205, 209, 221, 249, 253, 262, 265, 289, 298, 302, 305, 309, 346, 358, 361, 365, 381, 382, 386, 413, 446, 466, 473, 485, 489, 493, 501, 505, 514, 526, 553
Offset: 1

Views

Author

Jonathan Vos Post, Oct 21 2005

Keywords

Comments

This is analogous to Sophie Germain semiprimes A111153 and the chains shown are analogous to Cunningham chains of the second kind and Tomaszewski chains of the second kind. Define a 3n-1 semiprime chain of length k. This is a sequence of semiprimes s(1) < s(2) < ... < s(k) such that s(i+1) = 3*s(i) - 1 for i = 1, ..., k-1. Length 3: 9, 26, 77; 49, 146, 437; 65, 194, 581; 129, 386, 1157; 158, 473, 1418; 187, 562, 1685. Length 4: 74, 221, 662, 1985; 122, 365, 1094, 3281. Length 5: 21, 62, 185, 554, 1661.

Examples

			n s(n) 3 *s -1
1 9 = 3^2 26 = 2 * 13
2 21 = 3 * 7 62 = 2 * 31
3 22 = 2 * 11 65 = 5 * 13
4 25 = 5^2 74 = 2 * 37
5 26 = 2 * 13 77 = 7 * 11
6 49 = 7^2 146 = 2 * 73
		

Crossrefs

Programs

  • Mathematica
    Select[Range[600],PrimeOmega[#]==PrimeOmega[3#-1]==2&] (* Harvey P. Dale, Jun 20 2018 *)

Formula

{a(n)} = a(n) is an element of A001358 and 3*a(n)-1 is an element of A001358.

Extensions

Corrected and extended by Ray Chandler, Oct 22 2005

A211162 Sophie Germain 5-almost primes.

Original entry on oeis.org

688, 1552, 3496, 4360, 5008, 6352, 6952, 7546, 7672, 9256, 9625, 9712, 10062, 10300, 10840, 11632, 11875, 12112, 12136, 12460, 12712, 13432, 13648, 13744, 13912, 14152, 14812, 14920, 15484, 16562, 17050, 17104, 17272, 17608, 17752, 18130, 18232, 18616, 18952, 19062, 19624, 19792, 21100, 21136, 21352
Offset: 1

Views

Author

Keywords

Comments

Numbers n that are products of exactly 5 primes, such that 2*n + 1 are also products of exactly 5 primes. By analogy with A111153 Sophie Germain semiprimes: semiprimes n such that 2n+1 is also a semiprime; A111173 Sophie Germain 3-almost primes; A111176 Sophie Germain 4-almost primes.
From Zak Seidov, Jan 30 2013: (Start)
First integers n such that both n and 2n+1 are Sophie Germain 5-almost primes are: 54708, 103812, 111952, 113368, 117328, 134312, 159568, 160062, 165462, 199048, 205812.
First integers n such that n, 2n+1 and 4n+3 all are Sophie Germain 5-almost primes are: 159568, 301812, 431068, 444388, 564718, 1144468, 1420468, 1653162, 1687768, 1794568.
First integers n such that n, 2n+1, 4n+3 and 8n+7 all are Sophie Germain 5-almost primes are: 2991345, 4553367, 7760616, 9145318, 9332368, 12919266, 14283535, 14659746, 15144118.
First integers n such that n, 2n+1, 4n+3, 8n+7 and 16n+15 all are Sophie Germain 5-almost primes are: 15144118, 18515752, 41092024, 60406662, 71783890, 87353512, 94144212
First integers n such that n, 2n+1, 4n+3, 8n+7, 16n+15 and 32n+31 all are Sophie Germain 5-almost primes are: 211457337, 237572475, 245071092, 352015408, 415695462, 433833417.
First integers n such that n, 2n+1, 4n+3, 8n+7, 16n+15, 32n+31 and 64n+63 all are Sophie Germain 5-almost primes are: 433833417, 463078210, 648871975. (End)

Examples

			a(1) = 688 because 688 = 2^4 * 43, and 2*688 + 1 = 1377 = 3^4 * 17.
		

Crossrefs

Programs

  • Magma
    Is5primes:=func; [n: n in [2..22000] | Is5primes(n) and Is5primes(2*n+1)]; // Bruno Berselli, Jan 30 2013
    
  • Mathematica
    fQ[n_] := PrimeOmega[n] == 5 == PrimeOmega[2 n + 1]; Select[Range@ 100000, fQ] (* Robert G. Wilson v *)
  • PARI
    is(n)=bigomega(n)==5 && bigomega(2*n+1)==5 \\ Charles R Greathouse IV, Feb 01 2017

Formula

{n in A014614 such that 2*n + 1 is in A014614}.

A211169 The least n-almost Sophie Germain prime.

Original entry on oeis.org

2, 4, 52, 40, 688, 4900, 63112, 178240, 38272, 5357056, 1997824, 247221760, 586504192, 707436544, 15582115840, 47145459712, 77620412416, 1871289057280, 17787921498112, 10891875057664, 146305150615552, 535618317844480, 15921951753109504, 39754688251297792
Offset: 1

Views

Author

Keywords

Examples

			a(1)=2 because 2 and 5 are primes (A000040),
a(2)=4 because 4 and 9 are semiprimes (A001358),
a(3)=52 because the pair, 52 and 105, are 3-almost primes (A014612) and they are the least such pair,
a(4)=40 because the pair, 40 and 81, are 4-almost primes (A014613) and they are the least such pair, etc.
		

Crossrefs

Cf. A005384 (Sophie Germain primes), A111153 (Sophie Germain semiprimes), A111173 (Sophie Germain 3-almost primes), A111176 (Sophie Germain 4-almost primes), A211162 (Sophie Germain 5-almost primes).

Programs

  • Maple
    with(numtheory);
    A211169:=proc(q)
    local a,b,c,d,g,f,i,j,n;
    for j from 1 to q do for n from 1 to q do
        a:=ifactors(n)[2]; b:=nops(a); c:=ifactors(2*n+1)[2]; d:=nops(c); g:=0; f:=0;
        for i from 1 to b do g:=g+a[i][2]; od; for i from 1 to d do f:=f+c[i][2]; od;
        if g=f and g=j then print(n); break;
    fi; od; od; end:
    A211169(1000000000000);
  • Mathematica
    t = Table[0, {20}]; k = 2; While[k < 2700000001, x = PrimeOmega[k]; If[ t[[x]] == 0 && PrimeOmega[ 2k + 1] == x, t[[x]] = k; Print[{x, k}]]; k++]; t

Extensions

a(15)-a(24) from Giovanni Resta, Jan 31 2013

A238257 Numbers n such that n and 2n+1 use only odd decimal digits.

Original entry on oeis.org

1, 3, 5, 7, 9, 15, 17, 19, 35, 37, 39, 55, 57, 59, 75, 77, 79, 95, 97, 99, 155, 157, 159, 175, 177, 179, 195, 197, 199, 355, 357, 359, 375, 377, 379, 395, 397, 399, 555, 557, 559, 575, 577, 579, 595, 597, 599, 755, 757, 759, 775, 777, 779, 795, 797, 799, 955, 957, 959, 975, 977, 979, 995, 997, 999, 1555, 1557, 1559, 1575, 1577, 1579
Offset: 1

Views

Author

Zak Seidov, Feb 21 2014

Keywords

Comments

Sophie-Germain-analog for numbers with odd digits.
Also numbers with the first digit an odd digit and the other digits in {5, 7, 9}. - David A. Corneth, May 15 2018

Crossrefs

Programs

  • Mathematica
    Select[Range[1600],AllTrue[Join[IntegerDigits[#],IntegerDigits[ 2#+1]], OddQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, May 15 2018 *)
  • PARI
    is(n)=#setminus(setunion(Set(digits(n)),Set(digits(2*n+1))), [1,3,5,7,9])==0 \\ Charles R Greathouse IV, May 15 2018

Formula

a(5(3^k-1)/2) = 10^k-1. - Giovanni Resta, Feb 22 2014
Showing 1-8 of 8 results.