OFFSET
1,2
COMMENTS
These are the prime powers p^e with e <= p. - Reinhard Zumkeller, Dec 15 2003
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
FORMULA
MATHEMATICA
sopfr[n_] := Total[Times @@@ FactorInteger[n]];
S[n_] := Module[{m = 1}, While[!IntegerQ[m!/n], m++]; m];
Select[Range[1000], sopfr[#] == S[#]&] (* Jean-François Alcover, Nov 09 2017 *)
PROG
(Haskell)
import Data.Set (singleton, deleteFindMin, insert)
a074583 n = a074583_list !! (n-1)
a074583_list = 1 : f (singleton 2) a000040_list where
f s ps'@(p:p':ps)
| m == p = p : f (insert (p*p) $ insert p' s') (p':ps)
| m < spf^spf = m : f (insert (m*spf) s') ps'
| otherwise = m : f s' ps'
where spf = a020639 m -- smallest prime factor of m, cf. A020639
(m, s') = deleteFindMin s
-- Simpler version:
a074583_list = map a000961 a192188_list
-- Reinhard Zumkeller, Jun 05 2011, Jun 26 2011
(PARI) isok(n) = my(f=factor(n)); n==1 || (#f~==1 && f[1, 1]>=f[1, 2]); \\ Seiichi Manyama, May 07 2021
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Jason Earls, Aug 24 2002
STATUS
approved