A325273 Prime omicron of n!.
0, 0, 1, 2, 2, 2, 3, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 2, 2, 2, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2
Offset: 0
Keywords
Links
- James Rayman, Table of n, a(n) for n = 0..10000
Crossrefs
Programs
-
Mathematica
omseq[n_Integer]:=If[n<=1,{},Total/@NestWhileList[Sort[Length/@Split[#]]&,Sort[Last/@FactorInteger[n]],Total[#]>1&]]; omicron[n_]:=Switch[n,1,0,?PrimeQ,1,,omseq[n][[-2]]]; Table[omicron[n!],{n,0,100}]
-
Python
from sympy.ntheory import * def red(v): r = {} for i in v: r[i] = r.get(i, 0) + 1 return r def omicron(v): if len(v) == 0: return 0 if len(v) == 1: return v[0] else: return omicron(list(red(v).values())) f, a_list = {}, [] for i in range(101): a_list.append(omicron(list(f.values()))) g = factorint(i+1) for k in g: f[k] = f.get(k, 0) + g[k] print(a_list) # James Rayman, Apr 17 2021
Extensions
More terms from James Rayman, Apr 17 2021
Comments