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

A070552 Semiprimes k such that k+1 is also a semiprime.

Original entry on oeis.org

9, 14, 21, 25, 33, 34, 38, 57, 85, 86, 93, 94, 118, 121, 122, 133, 141, 142, 145, 158, 177, 201, 202, 205, 213, 214, 217, 218, 253, 298, 301, 302, 326, 334, 361, 381, 393, 394, 445, 446, 453, 481, 501, 514, 526, 537, 542, 553, 565, 622, 633, 634, 694, 697
Offset: 1

Views

Author

Sharon Sela (sharonsela(AT)hotmail.com), May 03 2002

Keywords

Comments

A064911(a(n))*A064911(a(n)+1) = 1. - Reinhard Zumkeller, Dec 03 2009

Crossrefs

Programs

  • Magma
    IsSemiprime:=func< n | &+[k[2]: k in Factorization(n)] eq 2 >; [ n: n in [4..700] | IsSemiprime(n) and IsSemiprime(n+1) ]; // Vincenzo Librandi, Jan 22 2016
    
  • Mathematica
    f[n_]:=Last/@FactorInteger[n]=={1,1}||Last/@FactorInteger[n]=={2};lst={};Do[If[f[n]&&f[n+1],AppendTo[lst,n]],{n,7!}];lst (* Vladimir Joseph Stephan Orlovsky, Feb 25 2010 *)
    Flatten[Position[Partition[Table[If[PrimeOmega[n]==2,1,0],{n,700}],2,1],{1,1}]] (* Harvey P. Dale, Feb 04 2015 *)
    Select[Range[700], PrimeOmega[#] == PrimeOmega[# + 1] == 2 &] (* Vincenzo Librandi, Jan 22 2016 *)
  • PARI
    forprime(p=3,1e3,if(bigomega(2*p-1)==2,print1(2*p-1", "));if(bigomega(2*p+1)==2,print1(2*p", "))) \\ Charles R Greathouse IV, Nov 09 2011
    
  • PARI
    is(n)=if(n%2, isprime((n+1)/2) && bigomega(n)==2, isprime(n/2) && bigomega(n+1)==2) \\ Charles R Greathouse IV, Sep 08 2015
    
  • Python
    from sympy import factorint
    def is_semiprime(n): return sum(e for e in factorint(n).values()) == 2
    def ok(n): return is_semiprime(n) and is_semiprime(n+1)
    print(list(filter(ok, range(698)))) # Michael S. Branicky, Sep 14 2021

Formula

a(n) >> n log n since either n or n+1 is in A100484. - Charles R Greathouse IV, Jul 21 2015
a(n) = A109373(n) - 1. - Zak Seidov Dec 19 2018

Extensions

More terms from Vladeta Jovovic, May 03 2002

A039833 Smallest of three consecutive squarefree numbers k, k+1, k+2 of the form p*q where p and q are distinct primes.

Original entry on oeis.org

33, 85, 93, 141, 201, 213, 217, 301, 393, 445, 633, 697, 921, 1041, 1137, 1261, 1345, 1401, 1641, 1761, 1837, 1893, 1941, 1981, 2101, 2181, 2217, 2305, 2361, 2433, 2461, 2517, 2641, 2721, 2733, 3097, 3385, 3601, 3693, 3865, 3901, 3957, 4285, 4413, 4533, 4593, 4881, 5601
Offset: 1

Views

Author

Keywords

Comments

Equivalently: k, k+1 and k+2 all have 4 divisors.
There cannot be four consecutive squarefree numbers as one of them is divisible by 2^2 = 4.
These 3 consecutive squarefree numbers of the form p*q have altogether 6 prime factors always including 2 and 3. E.g., if k = 99985, the six prime factors are {2,3,5,19997,33329,49993}. The middle term is even and not divisible by 3.
Nonsquare terms of A056809. First terms of A056809 absent here are A056809(4)=121=11^2, A056809(14)=841=29^2, A056809(55)=6241=79^2.
Cf. A179502 (Numbers k with the property that k^2, k^2+1 and k^2+2 are all semiprimes). - Zak Seidov, Oct 27 2015
The numbers k, k+1, k+2 have the form 2p-1, 2p, 2p+1 where p is an odd prime. A195685 gives the sequence of odd primes that generates these maximal runs of three consecutive integers with four positive divisors. - Timothy L. Tiffin, Jul 05 2016
a(n) is always 1 or 9 mod 12. - Charles R Greathouse IV, Mar 19 2022

Examples

			33, 34 and 35 all have 4 divisors.
85 is a term as 85 = 17*5, 86 = 43*2, 87 = 29*3.
		

References

  • R. K. Guy, Unsolved Problems in Number Theory, Springer, 1st edition, 1981. See section B18.
  • David Wells, Curious and interesting numbers, Penguin Books, 1986, p. 114.

Crossrefs

Programs

  • Haskell
    a039833 n = a039833_list !! (n-1)
    a039833_list = f a006881_list where
       f (u : vs@(v : w : xs))
         | v == u+1 && w == v+1 = u : f vs
         | otherwise            = f vs
    -- Reinhard Zumkeller, Aug 07 2011
    
  • Mathematica
    lst = {}; Do[z = n^3 + 3*n^2 + 2*n; If[PrimeOmega[z/n] == PrimeOmega[z/(n + 2)] == 4 && PrimeNu[z] == 6, AppendTo[lst, n]], {n, 1, 5601, 2}]; lst (* Arkadiusz Wesolowski, Dec 11 2011 *)
    okQ[n_]:=Module[{cl={n,n+1,n+2}},And@@SquareFreeQ/@cl && Union[ DivisorSigma[ 0,cl]]=={4}]; Select[Range[1,6001,2],okQ] (* Harvey P. Dale, Dec 17 2011 *)
    SequencePosition[DivisorSigma[0,Range[6000]],{4,4,4}][[All,1]] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Aug 17 2017 *)
  • PARI
    is(n)=n%4==1 && factor(n)[,2]==[1,1]~ && factor(n+1)[,2]==[1,1]~ && factor(n+2)[,2]==[1,1]~ \\ Charles R Greathouse IV, Aug 29 2016
    
  • PARI
    is(n)=my(t=n%12); if(t==1, isprime((n+2)/3) && isprime((n+1)/2) && factor(n)[,2]==[1,1]~, t==9 && isprime(n/3) && isprime((n+1)/2) && factor(n+2)[,2]==[1,1]~) \\ Charles R Greathouse IV, Mar 19 2022

Formula

A008966(a(n)) * A064911(a(n)) * A008966(a(n)+1) * A064911(a(n)+1) * A008966(a(n)+2) * A064911(a(n)+2) = 1. - Reinhard Zumkeller, Feb 26 2011

Extensions

Additional comments from Amarnath Murthy, Vladeta Jovovic, Labos Elemer and Benoit Cloitre, May 08 2002

A274357 Numbers n such that n and n+1 both have 8 divisors.

Original entry on oeis.org

104, 135, 189, 230, 231, 285, 296, 344, 374, 375, 429, 434, 609, 645, 663, 664, 741, 776, 782, 805, 874, 902, 903, 969, 986, 1001, 1015, 1022, 1029, 1065, 1085, 1095, 1105, 1106, 1112, 1130, 1161, 1208, 1221, 1245, 1265, 1269, 1309, 1310, 1334, 1335, 1374, 1406, 1431
Offset: 1

Views

Author

Keywords

Crossrefs

Intersection of A005237 and A030626.
Numbers n such that n and n+1 both have k divisors: A039832 (k=4), A049103 (k=6), A274357 (k=8), A215197 (k=10), A174456 (k=12), A274358 (k=14), A274359 (k=16), A274360 (k=18), A274361 (k=20), A274366 (k=22), A274362 (k=24), A274363 (k=26), A274364 (k=28), A274365 (k=30).
Cf. A000005.

Programs

  • Mathematica
    SequencePosition[DivisorSigma[0,Range[2000]],{8,8}][[All,1]] (* Harvey P. Dale, Sep 07 2021 *)
  • PARI
    is(n)=numdiv(n)==8 && numdiv(n+1)==8

A075036 Smaller of two smallest consecutive numbers with 2n divisors.

Original entry on oeis.org

2, 14, 44, 104, 2511, 735, 29888, 2295, 6075, 5264, 2200933376, 5984, 689278976, 156735, 180224, 21735, 2035980763136, 223244, 9399153082499072, 458864, 41680575, 701443071, 2503092614937444351, 201824, 2707370000, 29785673727, 46977524, 5475519, 1737797404898095794225152
Offset: 1

Views

Author

Amarnath Murthy, Sep 03 2002

Keywords

Comments

There cannot be two consecutive numbers with the same odd number of divisors as both cannot be squares.
These numbers have the property that a(n) * (a(n) + 1) has 4*n^2 divisors. - David A. Corneth, Jun 24 2016
Conjecture: if a term k is even, the highest p-adic order of k (the maximum may be attained by several p's) occurs at p=2 and the highest p-adic order of k+1 occurs at p=3. If a term k is odd, the highest p-adic order of k occurs at p=3 and the highest p-adic order of k+1 occurs at p=2. - Chai Wah Wu, Mar 12 2019
a(49) = 378401464109375, a(58) = 79921490583489592950783. - Jon E. Schoenfield, May 07 2022
a(51) = 34210814718574592, a(55) = 2481402804069375, a(57) = 394311388855795712. - Jon E. Schoenfield, Nov 06 2023 - Nov 08 2023

Examples

			a(4) = 104 as tau(104) = tau(105) = 8.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := (For[k=1, ! (DivisorSigma[0, k] == 2*n && DivisorSigma[0, k+1] == 2*n), k++]; k); Array[a, 10] (* Giovanni Resta, Jun 24 2016 *)
  • PARI
    a(n) = my(k=1); while(numdiv(k)!=2*n || numdiv(k+1)!=2*n, k++); k \\ Felix Fröhlich, Jun 24 2016

Formula

a(n) <= A215199(n-1) for n > 1. Conjecture: if p is prime, then a(p) = A215199(p-1). This conjecture is true if the conjecture in A215199 is true. The b-file of A215199 thus shows that a(p) = A215199(p-1) for prime p < 1279. - Chai Wah Wu, Mar 12 2019

Extensions

a(5)-a(24) from Max Alekseyev, Mar 12 2009
a(25)-a(28) from Giovanni Resta, Jun 24 2016
a(29) from Chai Wah Wu, Mar 12 2019

A038456 List of pairs of consecutive numbers each with 4 divisors (duplicates removed).

Original entry on oeis.org

14, 15, 21, 22, 26, 27, 33, 34, 35, 38, 39, 57, 58, 85, 86, 87, 93, 94, 95, 118, 119, 122, 123, 133, 134, 141, 142, 143, 145, 146, 158, 159, 177, 178, 201, 202, 203, 205, 206, 213, 214, 215, 217, 218, 219, 253, 254, 298, 299, 301, 302, 303, 326, 327, 334, 335, 381, 382, 393, 394, 395, 445, 446, 447, 453, 454
Offset: 1

Views

Author

Keywords

Examples

			14 and 15 because both have 4 as number of divisors and are consecutive.
		

References

  • D. Wells, Curious and interesting numbers, Penguin Books.

Crossrefs

Programs

  • Mathematica
    Union[Flatten[Select[Partition[Range[500],2,1],DivisorSigma[0,First[#]] == DivisorSigma[0,Last[#]]==4&]]] (* Harvey P. Dale, Jul 22 2012 *)
    SequencePosition[DivisorSigma[0,Range[500]],{4,4}]//Flatten//Union (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Aug 15 2016 *)
  • PARI
    isA038456(n) = (numdiv(n)==4) && ((numdiv(n+1)==4) || (numdiv(n-1)==4)) \\ Michael B. Porter, Feb 03 2010

Extensions

Corrected and extended by Olivier Gérard
Corrected by Rick L. Shepherd, Jun 07 2002

A356742 Numbers k such that k and k+2 both have exactly 4 divisors.

Original entry on oeis.org

6, 8, 33, 55, 85, 91, 93, 123, 141, 143, 159, 183, 185, 201, 203, 213, 215, 217, 219, 235, 247, 265, 299, 301, 303, 319, 321, 327, 339, 341, 391, 393, 411, 413, 415, 445, 451, 469, 471, 515, 517, 533, 535, 543, 551, 579, 581, 589, 633, 667, 669, 679, 685, 687, 695, 697
Offset: 1

Views

Author

Jianing Song, Aug 25 2022

Keywords

Comments

6 and 8 are the only even terms: one of the two consecutive even numbers is divisible by 4, and the only multiple of 4 with exactly 4 divisors is 8.

Examples

			341 is a term since 341 and 343 both have 4 divisors.
		

Crossrefs

Numbers k such that k and k+2 both have exactly m divisors: A001359 (m=2), this sequence (m=4), A356743 (m=6), A356744 (m=8).
Cf. also A039832 (numbers k such that k and k+1 both have exactly 4 divisors).

Programs

A164119 Numbers k that are the smallest number that produces the ordered pair (d(k), d(k+1)), where d(k) is the number of divisors of k.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 9, 11, 12, 14, 15, 16, 20, 23, 24, 27, 30, 35, 36, 39, 44, 47, 48, 49, 54, 59, 60, 63, 64, 80, 81, 84, 95, 99, 104, 111, 112, 119, 120, 143, 144, 152, 153, 167, 169, 175, 176, 179, 180, 191, 192, 195, 210, 216, 224, 225, 239, 240, 252, 260, 272, 275
Offset: 1

Views

Author

T. D. Noe, Aug 10 2009

Keywords

Comments

The set of numbers that produces a given ordered pair (i,j) is either empty, finite, or infinite. The pair (3,3) is produced by no number because d(k)=3 only if k is the square of a prime and no two consecutive numbers are squares of primes. Sequence A161460 lists numbers k that produce a unique ordered pair. It appears that the ordered pair (4,2) is produced by an infinite number of k, which is another way of conjecturing that there are an infinite number of safe primes, A005385. The pair (2,4) is produced by primes in A005383. The numbers in A039832 produce the pair (4,4).

Examples

			7 is not here because (d(7), d(8)) = (2,4), which is the same ordered pair produced by k=5.
		

Crossrefs

Programs

  • Mathematica
    s={}; Reap[Do[pr=DivisorSigma[0,{n,n+1}]; If[ !MemberQ[s,pr], AppendTo[s,pr]; Sow[n]], {n,1000}]][[2,1]]
Showing 1-7 of 7 results.