A078972
Brilliant numbers: semiprimes (products of two primes, A001358) whose prime factors have the same number of decimal digits.
Original entry on oeis.org
4, 6, 9, 10, 14, 15, 21, 25, 35, 49, 121, 143, 169, 187, 209, 221, 247, 253, 289, 299, 319, 323, 341, 361, 377, 391, 403, 407, 437, 451, 473, 481, 493, 517, 527, 529, 533, 551, 559, 583, 589, 611, 629, 649, 667, 671, 689, 697, 703, 713, 731, 737, 767, 779, 781
Offset: 1
1711 = 29*59 is in the sequence since both of its factors have two digits.
- P. D. James, The Private Patient, Knopf, NY, 2008, p. 192. (from N. J. A. Sloane, Aug 27 2009)
-
import Data.Function (on)
a078972 n = a078972_list !! (n-1)
a078972_list = filter brilliant a001358_list where
brilliant x = (on (==) a055642) p (x `div` p) where p = a020639 x
-- Reinhard Zumkeller, Nov 10 2013, Mar 22 2014
-
fQ[n_] := Block[{fi = FactorInteger@n}, Plus @@ Last /@ fi == 2 && Floor[ Log[10, fi[[1, 1]] ]] == Floor[ Log[10, fi[[ -1, 1]] ]]]; Select[ Range@792, fQ@# &] (* Robert G. Wilson v, May 26 2006 *)
Select[Range[800],PrimeOmega[#]==2&&Length[Union[IntegerLength[FactorInteger[#][[;;,1]]]]]==1&] (* Harvey P. Dale, Jan 24 2025 *)
Select[Range@1000, Differences@IntegerLength@Flatten@(ConstantArray@@#&/@FactorInteger[#]) == {0} &] (* Hans Rudolf Widmer, Oct 25 2022 *)
dlist2[d_] := Union[Times @@@ Tuples[Prime[Range[PrimePi[10^(d-1)] + 1, PrimePi[10^d]]], 2]]; (* Generates terms with d-digits prime factors *)
Flatten[Array[dlist2, 2]] (* Paolo Xausa, Oct 05 2024 *)
-
is(n)=my(f=factor(n));(#f[,1]==1 && f[1,2]==2) || (#f[,1]==2 && f[1,2]==1 && f[2,2]==1 && #Str(f[1,1])==#Str(f[2,1])) \\ Charles R Greathouse IV, Jun 16 2011
-
from sympy import sieve
A078972 = []
for n in range(3):
pr = list(sieve.primerange(10**n,10**(n+1)))
for i,p in enumerate(pr):
for q in pr[i:]:
A078972.append(p*q)
A078972 = sorted(A078972)
# Chai Wah Wu, Aug 26 2014
A338898
Concatenated sequence of prime indices of semiprimes (A001358).
Original entry on oeis.org
1, 1, 1, 2, 2, 2, 1, 3, 1, 4, 2, 3, 2, 4, 1, 5, 3, 3, 1, 6, 2, 5, 1, 7, 3, 4, 1, 8, 2, 6, 1, 9, 4, 4, 2, 7, 3, 5, 2, 8, 1, 10, 1, 11, 3, 6, 2, 9, 1, 12, 4, 5, 1, 13, 3, 7, 1, 14, 2, 10, 4, 6, 2, 11, 1, 15, 3, 8, 1, 16, 2, 12, 3, 9, 1, 17, 4, 7, 5, 5, 1, 18, 2
Offset: 1
The sequence of semiprimes together with their prime indices begins:
4: {1,1} 46: {1,9} 91: {4,6} 141: {2,15}
6: {1,2} 49: {4,4} 93: {2,11} 142: {1,20}
9: {2,2} 51: {2,7} 94: {1,15} 143: {5,6}
10: {1,3} 55: {3,5} 95: {3,8} 145: {3,10}
14: {1,4} 57: {2,8} 106: {1,16} 146: {1,21}
15: {2,3} 58: {1,10} 111: {2,12} 155: {3,11}
21: {2,4} 62: {1,11} 115: {3,9} 158: {1,22}
22: {1,5} 65: {3,6} 118: {1,17} 159: {2,16}
25: {3,3} 69: {2,9} 119: {4,7} 161: {4,9}
26: {1,6} 74: {1,12} 121: {5,5} 166: {1,23}
33: {2,5} 77: {4,5} 122: {1,18} 169: {6,6}
34: {1,7} 82: {1,13} 123: {2,13} 177: {2,17}
35: {3,4} 85: {3,7} 129: {2,14} 178: {1,24}
38: {1,8} 86: {1,14} 133: {4,8} 183: {2,18}
39: {2,6} 87: {2,10} 134: {1,19} 185: {3,12}
A112798 restricted to rows of length 2 gives this triangle.
A115392 is the row number for the first appearance of each positive integer.
A001221 counts a number's distinct prime indices.
A001222 counts a number's prime indices.
A006881 lists squarefree semiprimes.
A037143 lists primes and semiprimes.
A065516 gives first differences of semiprimes.
A320655 counts factorizations into semiprimes.
Cf.
A056239,
A101048,
A320892,
A320912,
A338900,
A338901,
A338904,
A338906,
A338907,
A338910,
A338911.
-
primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
Join@@primeMS/@Select[Range[100],PrimeOmega[#]==2&]
A072000
Number of semiprimes (A001358) <= n.
Original entry on oeis.org
0, 0, 0, 1, 1, 2, 2, 2, 3, 4, 4, 4, 4, 5, 6, 6, 6, 6, 6, 6, 7, 8, 8, 8, 9, 10, 10, 10, 10, 10, 10, 10, 11, 12, 13, 13, 13, 14, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 17, 17, 18, 18, 18, 18, 19, 19, 20, 21, 21, 21, 21, 22, 22, 22, 23, 23, 23, 23, 24, 24, 24, 24, 24, 25, 25, 25, 26
Offset: 1
- A. Hildebrand, On the number of prime factors of an integer, in Ramanujan Revisited (Urbana-Champaign, Ill., 1987), pp. 167-185, Academic Press, Boston, MA, 1988.
- E. Landau, Handbuch der Lehre von der Verteilung der Primzahlen, vol. 1, Teubner, Leipzig, 1909; third edition : Chelsea, New York (1974).
- G. Tenenbaum, Introduction à la théorie analytique et probabiliste des nombres, p. 203, Publications de l'Institut Cartan, 1990.
- Daniel Forgues, Table of n, a(n) for n = 1..40882
- Dragos Crisan and Radek Erban, On the counting function of semiprimes, arXiv:2006.16491 [math.NT], 2020.
- E. Landau, Handbuch der Lehre von der Verteilung der Primzahlen, vol. 1 and vol. 2, Leipzig, Berlin, B. G. Teubner, 1909.
- Eric Weisstein's World of Mathematics, Semiprime
-
A072000 := proc(n) local sp,t ; sp := 0 ; for t from 1 to n do if numtheory[bigomega](t) = 2 then sp := sp+1 ; fi ; od ; sp ; end proc: # R. J. Mathar, Jun 10 2007
-
semiPrimePi[n_] := Sum[ PrimePi[n/Prime@i] -i + 1, {i, PrimePi@Sqrt@n}]; Array[semiPrimePi, 78] (* Robert G. Wilson v, Jan 03 2006 *)
(* If version >= 7 *) a[n_] := Select[Range[n], PrimeOmega[#] == 2 &] // Length; Table[a[n], {n, 1, 77}] (* Jean-François Alcover, Jun 29 2013 *)
Accumulate[Table[If[PrimeOmega[n]==2,1,0],{n,100}]] (* Harvey P. Dale, Jun 14 2014 *)
-
for(n=1,100,print1(sum(i=1,n,if(bigomega(i)-2,0,1)),","))
-
a(n)=my(s=0,i=0); forprime(p=2, sqrt(n), s+=primepi(n\p); i++); s - i * (i-1)/2 \\ Charles R Greathouse IV, Apr 21 2011
-
from math import isqrt
from sympy import primepi, prime
def A072000(n): return int(sum(primepi(n//prime(k))-k+1 for k in range(1,primepi(isqrt(n))+1))) # Chai Wah Wu, Jul 23 2024
A085724
Numbers k such that 2^k - 1 is a semiprime (A001358).
Original entry on oeis.org
4, 9, 11, 23, 37, 41, 49, 59, 67, 83, 97, 101, 103, 109, 131, 137, 139, 149, 167, 197, 199, 227, 241, 269, 271, 281, 293, 347, 373, 379, 421, 457, 487, 523, 727, 809, 881, 971, 983, 997, 1061, 1063
Offset: 1
11 is a member because 2^11 - 1 = 23*89.
- J. Earls, Mathematical Bliss, Pleroma Publications, 2009, pages 56-60. ASIN: B002ACVZ6O [From Jason Earls, Nov 22 2009]
- J. Earls, "Cole Semiprimes," Mathematical Bliss, Pleroma Publications, 2009, pages 56-60. ASIN: B002ACVZ6O [From Jason Earls, Nov 25 2009]
-
SemiPrimeQ[n_]:=(n>1) && (2==Plus@@(Transpose[FactorInteger[n]][[2]])); Select[Range[100],SemiPrimeQ[2^#-1]&] (Noe)
Select[Range[1100],PrimeOmega[2^#-1]==2&] (* Harvey P. Dale, Feb 18 2018 *)
Select[Range[250], Total[Last /@ FactorInteger[2^# - 1, 3]] == 2 &] (* Eric W. Weisstein, Jul 28 2022 *)
-
issemi(n)=bigomega(n)==2
is(n)=if(isprime(n), issemi(2^n-1), my(q); isprimepower(n,&q)==2 && ispseudoprime(2^q-1) && ispseudoprime((2^n-1)/(2^q-1))) \\ Charles R Greathouse IV, Jun 05 2013
More terms from Cunningham project, Mar 23 2004
A104494
Positive integers n such that n^17 + 1 is semiprime (A001358).
Original entry on oeis.org
2, 58, 66, 166, 268, 270, 408, 600, 672, 808, 822, 970, 1050, 1090, 1150, 1200, 1212, 1380, 1578, 1752, 1912, 1950, 1986, 2016, 2038, 2292, 2340, 2548, 2590, 2656, 2718, 2800, 2856, 3162, 3300, 3342, 3738, 4138, 4152, 4228, 4270, 4272, 4362, 4782, 5080, 5166
Offset: 1
2^17 + 1 = 131073 = 3 * 43691,
58^17 + 1 = 951208868148684143308060622849 = 59 * 16122184205909900734034925811,
66^17 + 1 = 8555529718761317069203003539457 = 67 * 127694473414348015958253784171,
1050^17 + 1 = 2292018317801032401637344360351562500000000000000001 = 1051 * 2180797638250268698037435166842590390104662226451.
Cf.
A001358,
A006313,
A103854,
A104238,
A104335,
A105041,
A105066,
A105078,
A105122,
A105142,
A105237,
A104479.
-
IsSemiprime:=func< n | &+[ k[2]: k in Factorization(n) ] eq 2 >; [n: n in [1..1200]|IsSemiprime(n^17+1)]; // Vincenzo Librandi, Mar 10 2015
-
Select[Range[1000000], PrimeQ[# + 1] && PrimeQ[(#^17 + 1)/(# + 1)] &] (* Robert Price, Mar 10 2015 *)
Select[Range[5200],PrimeOmega[#^17+1]==2&] (* Harvey P. Dale, Mar 07 2017 *)
-
for(n=1,3000,if(!ispseudoprime(n^17+1),forprime(p=1,10^4,if((n^17+1)%p==0,if(ispseudoprime((n^17+1)/p),print1(n,", "));break)))) \\ Derek Orr, Mar 09 2015
A289182
Positions of odd semiprimes in A001358.
Original entry on oeis.org
3, 6, 7, 9, 11, 13, 15, 17, 18, 19, 20, 23, 24, 26, 28, 30, 31, 32, 34, 36, 37, 39, 40, 42, 43, 44, 46, 48, 49, 51, 53, 54, 56, 57, 59, 60, 61, 63, 65, 66, 68, 69, 71, 72, 74, 75, 77, 78, 79, 80, 81, 83, 85, 86, 89, 90, 91, 92, 94, 95, 97, 98
Offset: 1
-
sp=Select[Range[4,1000],2==PrimeOmega[#]&];Flatten[Position[Mod[sp, 2],1]]
-
lista(nn) = vsp = select(x->(bigomega(x)==2), vector(nn, k, k)); select(x->(x%2), vsp, 1); \\ Michel Marcus, Jul 02 2017
-
from math import isqrt
from sympy import primepi, primerange
def A289182(n):
def iterfun(f,n=0):
m, k = n, f(n)
while m != k: m, k = k, f(k)
return m
def f(x): return int(-((t:=primepi(s:=isqrt(x)))*(t-1)>>1)+sum(primepi(x//p) for p in primerange(3,s+1)))
return f(m:=iterfun(lambda x:int(n+x-f(x)),n))+primepi(m>>1) # Chai Wah Wu, Apr 03 2025
A096932
Smallest number having exactly s divisors, where s is the n-th semiprime (A001358).
Original entry on oeis.org
6, 12, 36, 48, 192, 144, 576, 3072, 1296, 12288, 9216, 196608, 5184, 786432, 36864, 12582912, 46656, 589824, 82944, 2359296, 805306368, 3221225472, 331776, 37748736, 206158430208, 746496, 3298534883328, 5308416, 13194139533312, 2415919104, 2985984, 9663676416
Offset: 1
-
s[n_] := Module[{f = FactorInteger[n], p, q}, If[Total[f[[;;,2]]] == 2, p=f[[1,1]]; q = n/p; 2^(q-1) * 3^(p-1) ,Nothing]]; Array[s, 100] (* Amiram Eldar, Apr 13 2024 *)
A104335
Positive integers n such that n^14 + 1 is semiprime (A001358).
Original entry on oeis.org
4, 74, 94, 116, 270, 464, 556, 654, 1140, 1156, 1246, 1306, 1736, 2464, 2470, 2604, 2804, 2836, 2900, 3054, 3890, 4006, 4056, 4330, 4736, 4780, 5016, 5294, 5340, 5486, 5700, 5834, 6434, 7114, 7304, 8626, 8880, 9164, 9546, 9744, 9980, 10086, 10166
Offset: 1
4^14 + 1 = 268435457 = 17 * 15790321,
74^14 + 1 = 147653612273582215982104577 = 5477 * 26958848324553992328301,
1140^14 + 1 = 6261349103849104148619671961600000000000001 = 1299601 * 4817901112610027345792802530622860401.
Cf.
A001358,
A085722,
A096173,
A186669,
A104238,
A103854,
A105041,
A105066,
A105078,
A105122,
A105142,
A105237,
A104335,
A104479,
A104494,
A104657,
A105282.
-
Select[ Range[2, 10422, 2], PrimeQ[ #^2 + 1] && PrimeQ[ #^12 - #^10 + #^8 - #^6 + #^4 - #^2 + 1] &] (*Robert G. Wilson v, Apr 18 2005 *)
Select[Range[2,10200,2],PrimeOmega[#^14+1]==2&] (* Harvey P. Dale, Oct 16 2011 *)
A104479
Positive integers n such that n^16 + 1 is semiprime (A001358).
Original entry on oeis.org
3, 4, 9, 12, 14, 16, 18, 20, 26, 29, 40, 41, 48, 58, 70, 73, 81, 87, 92, 96, 104, 111, 113, 114, 118, 122, 130, 140, 142, 144, 146, 150, 157, 162, 164, 167, 168, 172, 173, 184, 187, 192, 194, 195, 199, 200, 202, 208, 220, 230, 232, 244, 253, 256, 266, 278, 292, 295, 298
Offset: 1
3^16 + 1 = 43046722 = 2 * 21523361,
4^16 + 1 = 4294967297 = 641 * 6 700417,
9^16 + 1 = 1853020188851842 = 2 * 926510094425921,
12^16 + 1 = 184884258895036417 = 153953 * 1200913648289,
200^16 + 1 = 6553600000000000000000000000000000001 =
162123499503471553 * 40423504427621041217.
Cf.
A006313,
A001358,
A085722,
A096173,
A186669,
A104238,
A103854,
A105041,
A105066,
A105078,
A105122,
A105142,
A105237,
A104335,
A104479,
A104494,
A104657,
A105282.
-
IsSemiprime:=func< n | &+[ k[2]: k in Factorization(n) ] eq 2 >; [n: n in [2..300]|IsSemiprime(n^16+1)] // Vincenzo Librandi, Dec 21 2010
-
Select[Range[300],PrimeOmega[#^16+1]==2&] (* Harvey P. Dale, Aug 21 2011 *)
Select[Range[1000], 2 == Total[Transpose[FactorInteger[#^16 + 1]][[2]]] &] (* Robert Price, Mar 11 2015 *)
A104657
Positive integers n such that n^19 + 1 is semiprime (A001358).
Original entry on oeis.org
2, 10, 28, 106, 190, 292, 556, 756, 858, 906, 1012, 1030, 1032, 1060, 1372, 1450, 1488, 1720, 1722, 1758, 1782, 1822, 1972, 2356, 2436, 2446, 2620, 2748, 2788, 2998, 3186, 3300, 3318, 3360, 3466, 3510, 3822, 3852, 4138, 4326, 4506, 4908, 5236, 5518, 5782
Offset: 1
2^19 + 1 = 524289 = 3 * 174763,
10^19 + 1 = 10000000000000000001 = 11 * 909090909090909091,
1012^19 + 1 = 125438178100868833265294241234853844232270960601988910249 = 1013 * 1238284087866424810121364671617510801898035149081825373.
Cf.
A001358,
A006313,
A103854,
A104238,
A104335,
A105041,
A105066,
A105078,
A105122,
A105142,
A105237,
A104479,
A104494.
-
IsSemiprime:=func< n | &+[ k[2]: k in Factorization(n) ] eq 2 >; [n: n in [1..1100]|IsSemiprime(n^19+1)]; // Vincenzo Librandi, Mar 10 2015
-
Select[Range[1000000], PrimeQ[# + 1] && PrimeQ[(#^19 + 1)/(# + 1)] &] (* Robert Price, Mar 10 2015 *)
Select[Range[5800],PrimeOmega[#^19+1]==2&] (* Harvey P. Dale, Feb 15 2019 *)
Showing 1-10 of 1773 results.
Comments