A067813 Start of a record-breaking run of consecutive integers with a number of prime factors (counted with multiplicity) equal to 3.
8, 27, 170, 602, 2522, 211673
Offset: 1
Examples
a(4)=602 because 602 is the start of a record breaking run of 5 consecutive integers (602 to 606) each having 3 prime factors; i.e. bigomega(n)=A001222(n)=3 for n = 602, ..., 606.
Programs
-
Mathematica
bigomega[n_] := Plus@@Last/@FactorInteger[n]; For[n=1; m=l=0, True, n++, If[bigomega[n]==3, l++, If[l>m, m=l; Print[n-l, " ", l]]; l=0]] Module[{nn=8,po},po=PrimeOmega[Range[5000000]];Flatten[Table[ SequencePosition[ po,PadRight[{},n,3],1],{n,nn}],1]][[All,1]]//Union (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jun 14 2019 *)
-
PARI
show(lim)=my(was,r,ct); forfactored(n=2, lim\1+1, is=vecsum(n[2][, 2])==3; if(is, ct++; if(ct>r, r=ct; print(r" "n[1]-r+1)),ct=0)) \\ Charles R Greathouse IV, Jun 26 2019
Extensions
Edited by Dean Hickerson, Jul 31 2002
Comments