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-10 of 10 results.

A234093 Integers of the form (p*q - 1)/2, where p and q are distinct primes.

Original entry on oeis.org

7, 10, 16, 17, 19, 25, 27, 28, 32, 34, 38, 42, 43, 45, 46, 47, 55, 57, 59, 61, 64, 66, 70, 71, 72, 77, 79, 80, 88, 91, 92, 93, 100, 101, 102, 104, 106, 107, 108, 109, 110, 117, 118, 123, 124, 126, 129, 132, 133, 143, 145, 147, 149, 150, 151, 152, 154, 159
Offset: 1

Views

Author

Clark Kimberling, Dec 27 2013

Keywords

Comments

A102770 is subsequence. - Zak Seidov, Feb 21 2014

Examples

			(3*5 - 1)/2 = 7; (3*7 - 1)/2 = 10.
		

Crossrefs

Programs

  • Mathematica
    t = Select[Range[1, 7000, 2], Map[Last, FactorInteger[#]] == Table[1, {2}] &]; Take[(t - 1)/2, 120] (* A234093 *)
    v = Flatten[Position[PrimeQ[(t - 1)/2], True]] ; w = Table[t[[v[[n]]]], {n, 1, Length[v]}]  (* A233561 *)
    (w - 1)/2 (* A234095 *) (* Peter J. C. Moses, Dec 23 2013 *)
    With[{nn=60},Take[Union[Select[(Times@@#-1)/2&/@Subsets[Prime[ Range[ nn]],{2}],IntegerQ]],nn]] (* Harvey P. Dale, Mar 08 2015 *)

A286258 Compound filter: a(n) = P(A046523(n), A046523(2n+1)), where P(n,k) is sequence A000027 used as a pairing function.

Original entry on oeis.org

2, 5, 5, 25, 5, 27, 23, 44, 14, 61, 5, 117, 38, 27, 27, 226, 23, 90, 23, 90, 27, 142, 5, 375, 40, 27, 86, 148, 5, 495, 80, 698, 27, 61, 27, 702, 80, 61, 27, 765, 5, 625, 23, 90, 148, 61, 23, 1224, 109, 90, 27, 832, 5, 324, 61, 324, 61, 142, 23, 2013, 23, 84, 90, 2410, 27, 625, 302, 90, 27, 625, 23, 2998, 80, 27, 90, 265, 61, 495, 23, 1426, 152, 601, 5, 2013, 142, 27, 142
Offset: 1

Views

Author

Antti Karttunen, May 07 2017

Keywords

Crossrefs

Cf. A005384 (gives the positions of 5's), A234095 (of 23's).

Programs

  • PARI
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); };  \\ This function from Charles R Greathouse IV, Aug 17 2011
    A286258(n) = (1/2)*(2 + ((A046523(n)+A046523((2*n)+1))^2) - A046523(n) - 3*A046523((2*n)+1));
    for(n=1, 10000, write("b286258.txt", n, " ", A286258(n)));
    
  • Python
    from sympy import factorint
    def T(n, m): return ((n + m)**2 - n - 3*m + 2)/2
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def a(n): return T(a046523(n), a046523(2*n + 1)) # Indranil Ghosh, May 07 2017
  • Scheme
    (define (A286258 n) (* (/ 1 2) (+ (expt (+ (A046523 n) (A046523 (+ 1 n n))) 2) (- (A046523 n)) (- (* 3 (A046523 (+ 1 n n)))) 2)))
    

Formula

a(n) = (1/2)*(2 + ((A046523(n)+A046523((2*n)+1))^2) - A046523(n) - 3*A046523((2*n)+1)).

A233561 Products p*q of distinct primes such that (p*q - 1)/2 is prime.

Original entry on oeis.org

15, 35, 39, 87, 95, 119, 123, 143, 159, 203, 215, 219, 299, 303, 327, 335, 395, 447, 515, 527, 543, 623, 635, 695, 699, 707, 767, 779, 803, 843, 879, 899, 923, 959, 1007, 1043, 1047, 1115, 1139, 1199, 1203, 1227, 1263, 1347, 1355, 1383, 1403, 1623, 1643
Offset: 1

Views

Author

Clark Kimberling, Dec 14 2013

Keywords

Examples

			15 = 3*5 is the least product of distinct primes p and q for which (p*q - 1)/2 is prime, so a(1) = 15.
		

Crossrefs

Programs

  • Mathematica
    t = Select[Range[1, 7000, 2], Map[Last, FactorInteger[#]] == Table[1, {2}] &]; Take[(t - 1)/2, 120] (* A234093 *)
    v = Flatten[Position[PrimeQ[(t - 1)/2], True]] ; w = Table[t[[v[[n]]]], {n, 1, Length[v]}]  (* A233561 *)
    (w - 1)/2 (* A234095 *)  (* Peter J. C. Moses, Dec 23 2013 *)
    With[{upto=2000},Select[Times@@#&/@Select[Subsets[Prime[Range[ PrimePi[ upto/2]]],{2}],PrimeQ[(Times@@#-1)/2]&]//Union,#<=upto&]] (* Harvey P. Dale, Nov 02 2017 *)

A305978 Filter sequence combining prime signatures of n and 2n+1.

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 5, 6, 7, 8, 2, 9, 10, 4, 4, 11, 5, 12, 5, 12, 4, 13, 2, 14, 15, 4, 16, 17, 2, 18, 19, 20, 4, 8, 4, 21, 19, 8, 4, 22, 2, 23, 5, 12, 17, 8, 5, 24, 25, 12, 4, 26, 2, 27, 8, 27, 8, 13, 5, 28, 5, 29, 12, 30, 4, 23, 31, 12, 4, 23, 5, 32, 19, 4, 12, 33, 8, 18, 5, 34, 35, 36, 2, 28, 13, 4, 13, 37, 2, 38, 8, 17, 8, 39, 4, 40, 41, 12, 12, 42, 5, 23
Offset: 1

Views

Author

Antti Karttunen, Jun 15 2018

Keywords

Comments

Restricted growth sequence transform of A286258.

Crossrefs

Cf. A005384 (positions of 2's), A234095 (of 5's).

Programs

  • PARI
    up_to = 65537;
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); }; \\ From A046523
    Aux305978(n) = [A046523(n),A046523(n+n+1)];
    v305978 = rgs_transform(vector(up_to,n,Aux305978(n)));
    A305978(n) = v305978[n];

A234098 Primes of the form (p*q + 1)/2, where p and q are distinct primes.

Original entry on oeis.org

11, 17, 29, 43, 47, 67, 71, 73, 89, 101, 103, 107, 109, 127, 151, 191, 197, 223, 227, 241, 251, 269, 277, 283, 317, 349, 359, 373, 397, 409, 433, 457, 461, 467, 487, 521, 541, 569, 571, 631, 643, 647, 659, 673, 701, 709, 719, 733, 739, 751, 757, 769, 821
Offset: 1

Views

Author

Clark Kimberling, Dec 27 2013

Keywords

Examples

			11 = (3*7 + 1)/2, 17 = (5*7 + 1)/2.
		

Crossrefs

Programs

  • Haskell
    a234098 n = a234098_list !! (n-1)
    a234098_list = filter ((== 1) . a010051') $
                          map ((flip div 2) . (+ 1)) a046388_list
    -- Reinhard Zumkeller, Jan 02 2014
  • Mathematica
    t = Select[Range[1, 7000, 2], Map[Last, FactorInteger[#]] == Table[1, {2}] &]; Take[(t + 1)/2, 120] (* A234096 *)
    v = Flatten[Position[PrimeQ[(t + 1)/2], True]] ; w = Table[t[[v[[n]]]], {n, 1, Length[v]}]  (* A233562 *)
    (w + 1)/2 (* A234098 *)  (* Peter J. C. Moses, Dec 23 2013 *)
    Take[Select[(Times@@#+1)/2&/@Subsets[Prime[Range[200]],{2}],PrimeQ]//Union,60] (* Harvey P. Dale, Jun 24 2025 *)

A319706 Filter sequence which for primes p records the prime signature of 2p+1, and for all other numbers assigns a unique number.

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 5, 6, 7, 8, 2, 9, 10, 11, 12, 13, 5, 14, 5, 15, 16, 17, 2, 18, 19, 20, 21, 22, 2, 23, 24, 25, 26, 27, 28, 29, 24, 30, 31, 32, 2, 33, 5, 34, 35, 36, 5, 37, 38, 39, 40, 41, 2, 42, 43, 44, 45, 46, 5, 47, 5, 48, 49, 50, 51, 52, 53, 54, 55, 56, 5, 57, 24, 58, 59, 60, 61, 62, 5, 63, 64, 65, 2, 66, 67, 68, 69, 70, 2, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 5
Offset: 1

Views

Author

Antti Karttunen, Sep 26 2018

Keywords

Comments

Restricted growth sequence transform of function f defined as f(n) = A046523(2n+1) when n is a prime, otherwise -n.
For all i, j:
A305810(i) = A305810(j) => a(i) = a(j),
and
a(i) = a(j) => A305800(i) = A305800(j),
a(i) = a(j) => A305978(i) = A305978(j),
a(i) = a(j) => A305985(i) = A305985(j).

Crossrefs

Cf. A005384 (positions of 2's), A234095 (positions of 5's).

Programs

  • PARI
    up_to = 100000;
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); };  \\ From A046523
    A319706aux(n) = if(isprime(n),A046523(n+n+1),-n);
    v319706 = rgs_transform(vector(up_to,n,A319706aux(n)));
    A319706(n) = v319706[n];

A276045 Primes p such that d(p*(2p+1)) = 8 where d(n) is the number of divisors of n (A000005).

Original entry on oeis.org

7, 13, 17, 19, 43, 47, 59, 61, 71, 79, 101, 107, 109, 149, 151, 163, 167, 197, 223, 257, 263, 271, 311, 317, 347, 349, 353, 383, 389, 401, 421, 439, 449, 461, 479, 503, 521, 523, 557, 569, 599, 601, 613, 631, 673, 677, 691, 701, 811, 821, 827, 839, 853, 863, 881, 919
Offset: 1

Views

Author

Anthony Hernandez, Aug 17 2016

Keywords

Comments

Primes p such that 2p+1 is in A030513. - Robert Israel, Aug 17 2016
From Anthony Hernandez, Aug 29 2016: (Start)
Conjecture: this sequence is infinite.
It appears that the prime numbers in this sequence which have 7 for as final digit form the sequence A104164.
Conjecture: this sequence contains infinitely many twin primes. The first few twin primes in this sequence are 17,19,59,61,107,109,521,523,599,601,... (End)
From Bernard Schott, Apr 28 2020: (Start)
This sequence equals the union of {13} and A234095; proof by double inclusion:
-> 1st inclusion: {13} Union A234095 is included in A276045.
1) if p = 13, then 13*27 = 351 = 3^3 * 13, hence d(351) = 8 and 13 belongs to A276045.
2) if p is in A234095, then p*(2*p+1) = p*r*s (p,r,s primes) and d(p*r*s) = 8, hence p is in 276045.
-> 2nd inclusion: A276045 is included in {13} Union A234095.
If p is in A276095, then m=p*(2*p+1) has 8 divisors and there are only three possibilities: m = u*v*w, or m = u^3*v or m = u^7 with u, v, w are distinct primes.
1st case: if p*(2*p+1) = u*v*w then u=p, and 2p+1=v*w is semiprime; hence, p is in A234095 Union {13}.
2nd case: if p*(2p+1) = u^3*v then p=v and 2*p+1=u^3 ==> 2*p = u^3-1 = (u-1)*(u^2+u+1) with 2 and p are primes; then (u-1=2, u^2+u+1=p) so u=3, and p=3^2+3+1=13; hence p = 13 belongs to {13} Union A234095.
3rd case: p*(2p+1) = u^7 is impossible.
Conclusion: this sequence = {13} Union A234095. (End)

Examples

			d(7*(2*7+1))=d(105)=8 so 7 is a term.
		

Crossrefs

Equals {13} Union A234095.

Programs

  • Maple
    select(n -> isprime(n) and numtheory:-tau(n*(2*n+1))=8,
    [seq(i, i=3..1000, 2)]); # Robert Israel, Aug 17 2016
  • Mathematica
    Select[Prime@ Range@ 160, DivisorSigma[0, # (2 # + 1)] == 8 &] (* Michael De Vlieger, Aug 28 2016 *)
  • PARI
    lista(nn) = forprime(p=2, nn, if (numdiv(p*(2*p+1))==8, print1(p, ", "))); \\ Michel Marcus, Aug 17 2016

A235646 Primes p such that b=2*p+1 is semiprime, c=2*b+1 is 3-almost prime and d=2*c+1 is 4-almost prime.

Original entry on oeis.org

43, 1429, 2239, 3319, 4831, 6379, 8821, 10501, 11383, 12781, 13003, 14771, 15091, 16063, 16759, 18223, 19213, 19681, 20021, 22571, 24103, 24109, 24571, 25939, 27271, 28933, 29833, 30241, 31723, 33679, 33811, 34381, 34781, 35591, 35863, 39373
Offset: 1

Views

Author

Zak Seidov, Feb 20 2014

Keywords

Examples

			p = 43, b = 87 = 2*29 = A001358(30), c = 175 = 5*5*7 = A014612(43), d = 351 = 3*3*3**13 =  A014613(50).
		

Crossrefs

Subsequence of A238202.

Programs

  • Mathematica
    Select[ Prime@ Range@ 4200,PrimeOmega[2#+1]==2 && PrimeOmega[4#+3]==3 && PrimeOmega[8#+7]==4 &] (* Robert G. Wilson v, Feb 22 2014 *)
  • PARI
    forprime(p=43,40000,if(bigomega(a=2*p+1)==2&& bigomega(b=2*c+1)==3&&bigomega(c=2*d+1)==4,print(p",")))

A238202 Primes p such that b = 2*p + 1 is semiprime and c = 2*b + 1 is 3-almost prime.

Original entry on oeis.org

43, 503, 631, 827, 971, 1063, 1153, 1283, 1373, 1429, 1433, 1493, 1523, 1553, 1619, 1693, 1877, 2113, 2239, 2243, 2297, 2423, 2477, 2531, 2609, 2683, 2851, 2927, 2999, 3203, 3221, 3319, 3463, 3533, 3557, 3571, 3583, 3701
Offset: 1

Views

Author

Zak Seidov, Feb 20 2014

Keywords

Comments

Subsequence of A234095 and A000040, e.g., a(1) = 43 = A234095(4) = A000040(14).

Examples

			2*43 + 1 = 87 = 2*29 = A001358(30), 2*87 + 1 = 175 = 5*5*7 = A014612(43).
		

Crossrefs

Programs

  • PARI
    forprime(p=2,4000,if(bigomega(a=2*p+1)==2&&bigomega(b=2*a+1)==3,print(p",")))

A328058 Primes p such that 2*p-1 is a semiprime.

Original entry on oeis.org

5, 11, 13, 17, 29, 43, 47, 61, 67, 71, 73, 89, 101, 103, 107, 109, 127, 151, 181, 191, 197, 223, 227, 241, 251, 269, 277, 283, 317, 349, 359, 373, 397, 409, 421, 433, 457, 461, 467, 487, 521, 541, 569, 571, 631, 643, 647, 659, 673, 701, 709, 719, 733, 739, 751, 757, 769, 821, 857, 859, 881, 883
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Oct 03 2019

Keywords

Examples

			a(3)=13 is in the sequence because it is prime and 2*13-1=5^2 is a semiprime.
		

Crossrefs

Cf. A000040, A001358. Includes A067756 and A162336.

Programs

  • Magma
    [p: p in PrimesUpTo(1000)| &+[d[2]: d in Factorization(2*p-1)] eq 2]; // Marius A. Burtea, Oct 03 2019
    
  • Maple
    select(t -> isprime(t) and numtheory:-bigomega(2*t-1)=2, [2,seq(i,i=3..10000,2)]);
  • Mathematica
    Select[Prime@ Range@ 153, PrimeOmega[2 # - 1] == 2 &] (* Michael De Vlieger, Oct 03 2019 *)
  • PARI
    isok(p) = isprime(p) && (bigomega(2*p-1) == 2); \\ Michel Marcus, Oct 04 2019
Showing 1-10 of 10 results.